From 7a896f183dca54aa9d8529f5797920cf629f9210 Mon Sep 17 00:00:00 2001 From: Noel Grandin Date: Sat, 31 Oct 2020 22:04:03 +0200 Subject: use officecfg for Experimental flag move IsShowOutlineContentVisibilityButton out of header to avoid having to add extra include paths to all the unit test makefiles. Change-Id: I2763390e07cd85b8f09b6f2ad7702039daecb22f Reviewed-on: https://gerrit.libreoffice.org/c/core/+/105100 Tested-by: Jenkins Reviewed-by: Noel Grandin --- framework/source/uielement/menubarmanager.cxx | 3 ++- framework/source/uielement/toolbarmanager.cxx | 3 ++- framework/source/uielement/toolbarmodemenucontroller.cxx | 4 ++-- 3 files changed, 6 insertions(+), 4 deletions(-) (limited to 'framework/source') diff --git a/framework/source/uielement/menubarmanager.cxx b/framework/source/uielement/menubarmanager.cxx index 27f5ae2931e2..cff2f23a2178 100644 --- a/framework/source/uielement/menubarmanager.cxx +++ b/framework/source/uielement/menubarmanager.cxx @@ -44,6 +44,7 @@ #include #include +#include #include #include #include @@ -1329,7 +1330,7 @@ void MenuBarManager::FillMenu( } if (!aCommandURL.isEmpty() && vcl::CommandInfoProvider::IsExperimental(aCommandURL, rModuleIdentifier) && - !SvtMiscOptions().IsExperimentalMode()) + !officecfg::Office::Common::Misc::ExperimentalMode::get()) { continue; } diff --git a/framework/source/uielement/toolbarmanager.cxx b/framework/source/uielement/toolbarmanager.cxx index ea55656249ca..13e0efca691e 100644 --- a/framework/source/uielement/toolbarmanager.cxx +++ b/framework/source/uielement/toolbarmanager.cxx @@ -24,6 +24,7 @@ #include #include +#include #include #include #include @@ -1005,7 +1006,7 @@ void ToolBarManager::FillToolbar( const Reference< XIndexAccess >& rItemContaine } if (!aCommandURL.isEmpty() && vcl::CommandInfoProvider::IsExperimental(aCommandURL, m_aModuleIdentifier) && - !SvtMiscOptions().IsExperimentalMode()) + !officecfg::Office::Common::Misc::ExperimentalMode::get()) { continue; } diff --git a/framework/source/uielement/toolbarmodemenucontroller.cxx b/framework/source/uielement/toolbarmodemenucontroller.cxx index a03d31100efa..6faa4036efc3 100644 --- a/framework/source/uielement/toolbarmodemenucontroller.cxx +++ b/framework/source/uielement/toolbarmodemenucontroller.cxx @@ -29,6 +29,7 @@ #include +#include #include #include #include @@ -131,7 +132,6 @@ void ToolbarModeMenuController::fillPopupMenu( Reference< css::awt::XPopupMenu > const Sequence aModeNodeNames (aModesNode.getNodeNames()); const sal_Int32 nCount(aModeNodeNames.getLength()); - SvtMiscOptions aMiscOptions; tools::Long nCountToolbar = 0; for ( sal_Int32 nReadIndex = 0; nReadIndex < nCount; ++nReadIndex ) @@ -147,7 +147,7 @@ void ToolbarModeMenuController::fillPopupMenu( Reference< css::awt::XPopupMenu > bool hasNotebookbar = comphelper::getBOOL( aModeNode.getNodeValue( "HasNotebookbar" ) ); // Allow Notebookbar only in experimental mode - if ( isExperimental && !aMiscOptions.IsExperimentalMode() ) + if ( isExperimental && !officecfg::Office::Common::Misc::ExperimentalMode::get() ) continue; if (!hasNotebookbar) nCountToolbar++; -- cgit