diff options
-rw-r--r-- | sw/source/core/fields/chpfld.cxx | 4 | ||||
-rw-r--r-- | sw/source/core/fields/reffld.cxx | 4 |
2 files changed, 4 insertions, 4 deletions
diff --git a/sw/source/core/fields/chpfld.cxx b/sw/source/core/fields/chpfld.cxx index 957930f18af4..31dd91c4d50b 100644 --- a/sw/source/core/fields/chpfld.cxx +++ b/sw/source/core/fields/chpfld.cxx @@ -95,9 +95,9 @@ const OUString& SwChapterField::GetTitle(SwRootFrame const*const pLayout) const return rState.sTitle; } -OUString SwChapterField::ExpandImpl(SwRootFrame const*const) const +OUString SwChapterField::ExpandImpl(SwRootFrame const*const pLayout) const { - State const& rState(m_State); + State const& rState(pLayout && pLayout->IsHideRedlines() ? m_StateRLHidden : m_State); switch( GetFormat() ) { case CF_TITLE: diff --git a/sw/source/core/fields/reffld.cxx b/sw/source/core/fields/reffld.cxx index 127ea5964155..fc83fabbe343 100644 --- a/sw/source/core/fields/reffld.cxx +++ b/sw/source/core/fields/reffld.cxx @@ -416,9 +416,9 @@ void SwGetRefField::SetExpand( const OUString& rStr ) m_sTextRLHidden = rStr; } -OUString SwGetRefField::ExpandImpl(SwRootFrame const*const) const +OUString SwGetRefField::ExpandImpl(SwRootFrame const*const pLayout) const { - return m_sText; + return pLayout && pLayout->IsHideRedlines() ? m_sTextRLHidden : m_sText; } OUString SwGetRefField::GetFieldName() const |