[Libreoffice-commits] core.git: sw/source
Michael Stahl (via logerrit)
logerrit at kemper.freedesktop.org
Thu Nov 19 13:21:39 UTC 2020
sw/source/core/view/viewsh.cxx | 9 ++++++++-
1 file changed, 8 insertions(+), 1 deletion(-)
New commits:
commit c74a2fd835474caf311be10703c985e2f916a83b
Author: Michael Stahl <Michael.Stahl at cib.de>
AuthorDate: Tue Nov 3 22:06:52 2020 +0100
Commit: Michael Stahl <michael.stahl at cib.de>
CommitDate: Thu Nov 19 14:20:59 2020 +0100
sw_fieldmarkhide: toggle mode depending on View->Field Names
... in SwViewShell::ImplApplyViewOptions()
Change-Id: Ie7b41048fe6c222272b345995fcdca4129be8ef0
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/105987
Tested-by: Jenkins
Reviewed-by: Michael Stahl <michael.stahl at cib.de>
diff --git a/sw/source/core/view/viewsh.cxx b/sw/source/core/view/viewsh.cxx
index 1ef26c9e126f..1cc7288a6200 100644
--- a/sw/source/core/view/viewsh.cxx
+++ b/sw/source/core/view/viewsh.cxx
@@ -2222,9 +2222,16 @@ void SwViewShell::ImplApplyViewOptions( const SwViewOption &rOpt )
// - fieldnames apply or not ...
// ( - SwEndPortion must _no_ longer be generated. )
// - Of course, the screen is something completely different than the printer ...
- bReformat = bReformat || mpOpt->IsFieldName() != rOpt.IsFieldName();
bool const isToggleFieldNames(mpOpt->IsFieldName() != rOpt.IsFieldName());
+ if (mpOpt->IsFieldName() != rOpt.IsFieldName())
+ {
+ GetLayout()->SetFieldmarkMode( rOpt.IsFieldName()
+ ? sw::FieldmarkMode::ShowCommand
+ : sw::FieldmarkMode::ShowResult );
+ bReformat = true;
+ }
+
// The map mode is changed, minima/maxima will be attended by UI
if( mpOpt->GetZoom() != rOpt.GetZoom() && !IsPreview() )
{
More information about the Libreoffice-commits
mailing list