summaryrefslogtreecommitdiff
path: root/sfx2/source/appl
diff options
context:
space:
mode:
authorMaxim Monastirsky <momonasmon@gmail.com>2020-08-10 18:35:22 +0300
committerMaxim Monastirsky <momonasmon@gmail.com>2020-08-11 10:33:00 +0200
commit3239708375c81005d66627c09d1907848cd0cfda (patch)
treebd2f8424cbaa579627022d2f71e9f4ba88c3d7ea /sfx2/source/appl
parent7841adec312b4993156cdbd9702223e8f1f34132 (diff)
Simplify toolbar mode switching
Change-Id: I3bd809ce3ef661f6566a73e639fbd5e4bb1b7e3f Reviewed-on: https://gerrit.libreoffice.org/c/core/+/100439 Tested-by: Jenkins Reviewed-by: Maxim Monastirsky <momonasmon@gmail.com>
Diffstat (limited to 'sfx2/source/appl')
-rw-r--r--sfx2/source/appl/appserv.cxx8
1 files changed, 4 insertions, 4 deletions
diff --git a/sfx2/source/appl/appserv.cxx b/sfx2/source/appl/appserv.cxx
index 68f80d7e99e3..b07974a9b34a 100644
--- a/sfx2/source/appl/appserv.cxx
+++ b/sfx2/source/appl/appserv.cxx
@@ -892,6 +892,10 @@ void SfxApplication::MiscExec_Impl( SfxRequest& rReq )
}
}
+ // Show/Hide the Notebookbar
+ const SfxStringItem pItem(SID_NOTEBOOKBAR, aNewName);
+ pViewFrame->GetDispatcher()->ExecuteList(SID_NOTEBOOKBAR, SfxCallMode::SYNCHRON, {&pItem});
+
// Show toolbars
for ( const OUString& rName : std::as_const(aMandatoryToolbars) )
{
@@ -929,10 +933,6 @@ void SfxApplication::MiscExec_Impl( SfxRequest& rReq )
}
}
- // Show/Hide the Notebookbar
- const SfxPoolItem* pItem;
- pViewFrame->GetDispatcher()->QueryState( SID_NOTEBOOKBAR, pItem );
-
// Save settings
if ( pViewFrame == SfxViewFrame::Current() )
{