summaryrefslogtreecommitdiff
path: root/sw/source/ui/uno/unomod.cxx
diff options
context:
space:
mode:
Diffstat (limited to 'sw/source/ui/uno/unomod.cxx')
-rw-r--r--sw/source/ui/uno/unomod.cxx11
1 files changed, 8 insertions, 3 deletions
diff --git a/sw/source/ui/uno/unomod.cxx b/sw/source/ui/uno/unomod.cxx
index c19587f514f2..25b09c895687 100644
--- a/sw/source/ui/uno/unomod.cxx
+++ b/sw/source/ui/uno/unomod.cxx
@@ -776,8 +776,13 @@ void SwXViewSettings::_setSingleValue( const comphelper::PropertyInfo & rInfo, c
break;
case HANDLE_VIEWSET_ONLINE_LAYOUT :
{
- if( pView && !bVal != !pView->GetWrtShell().getIDocumentSettingAccess()->get(IDocumentSettingAccess::BROWSE_MODE) )
- pView->GetDocShell()->ToggleBrowserMode(bVal, pView );
+ if( pView && !bVal != !pView->GetWrtShell().GetViewOptions()->getBrowseMode() )
+ {
+ SwViewOption aOpt( *pView->GetWrtShell().GetViewOptions() );
+ aOpt.setBrowseMode( bVal );
+ pView->GetWrtShell().ApplyViewOptions( aOpt );
+ pView->RecheckBrowseMode();
+ }
}
break;
case HANDLE_VIEWSET_HELP_URL :
@@ -963,7 +968,7 @@ void SwXViewSettings::_getSingleValue( const comphelper::PropertyInfo & rInfo, u
break;
case HANDLE_VIEWSET_ONLINE_LAYOUT:
if(pView)
- bBoolVal = pView->GetWrtShell().getIDocumentSettingAccess()->get(IDocumentSettingAccess::BROWSE_MODE);
+ bBoolVal = pView->GetWrtShell().GetViewOptions()->getBrowseMode();
break;
case HANDLE_VIEWSET_HELP_URL :
{