summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--framework/source/uielement/toolbarmodemenucontroller.cxx13
-rw-r--r--officecfg/registry/data/org/openoffice/Office/UI/GenericCommands.xcu3
-rw-r--r--officecfg/registry/data/org/openoffice/Office/UI/ToolbarMode.xcu9
-rw-r--r--officecfg/registry/schema/org/openoffice/Office/UI/ToolbarMode.xcs5
4 files changed, 27 insertions, 3 deletions
diff --git a/framework/source/uielement/toolbarmodemenucontroller.cxx b/framework/source/uielement/toolbarmodemenucontroller.cxx
index 69aa1a6a027f..1e6cc36f31ca 100644
--- a/framework/source/uielement/toolbarmodemenucontroller.cxx
+++ b/framework/source/uielement/toolbarmodemenucontroller.cxx
@@ -117,6 +117,7 @@ void ToolbarModeMenuController::fillPopupMenu( Reference< css::awt::XPopupMenu >
const Sequence<OUString> aModeNodeNames (aModesNode.getNodeNames());
const sal_Int32 nCount(aModeNodeNames.getLength());
+ SvtMiscOptions aMiscOptions;
for ( sal_Int32 nReadIndex = 0; nReadIndex < nCount; ++nReadIndex )
{
@@ -128,6 +129,18 @@ void ToolbarModeMenuController::fillPopupMenu( Reference< css::awt::XPopupMenu >
OUString aCommandArg = comphelper::getString( aModeNode.getNodeValue( "CommandArg" ) );
long nPosition = comphelper::getINT32( aModeNode.getNodeValue( "MenuPosition" ) );
+ bool isExperimental = false;
+ if ( aModeNode.hasByName( "IsExperimental" ) )
+ {
+ Any aExperimentalNode = aModeNode.getNodeValue( "IsExperimental" );
+ if( aExperimentalNode.hasValue() )
+ isExperimental = comphelper::getBOOL( aExperimentalNode );
+ }
+
+ // Allow Notebookbar only in experimental mode
+ if ( isExperimental && !aMiscOptions.IsExperimentalMode() )
+ continue;
+
m_xPopupMenu->insertItem( nReadIndex+1, aLabel, css::awt::MenuItemStyle::RADIOCHECK, nPosition );
rPopupMenu->setCommand( nReadIndex+1, aCommandArg );
}
diff --git a/officecfg/registry/data/org/openoffice/Office/UI/GenericCommands.xcu b/officecfg/registry/data/org/openoffice/Office/UI/GenericCommands.xcu
index 7b78273f394a..0b860f7263ee 100644
--- a/officecfg/registry/data/org/openoffice/Office/UI/GenericCommands.xcu
+++ b/officecfg/registry/data/org/openoffice/Office/UI/GenericCommands.xcu
@@ -5893,9 +5893,6 @@
<prop oor:name="Label" oor:type="xs:string">
<value xml:lang="en-US">Toolbar Layout</value>
</prop>
- <prop oor:name="IsExperimental" oor:type="xs:boolean">
- <value>true</value>
- </prop>
</node>
<node oor:name=".uno:AvailableToolbars" oor:op="replace">
<prop oor:name="Label" oor:type="xs:string">
diff --git a/officecfg/registry/data/org/openoffice/Office/UI/ToolbarMode.xcu b/officecfg/registry/data/org/openoffice/Office/UI/ToolbarMode.xcu
index a78d90e009f6..4ee4b4fbcb44 100644
--- a/officecfg/registry/data/org/openoffice/Office/UI/ToolbarMode.xcu
+++ b/officecfg/registry/data/org/openoffice/Office/UI/ToolbarMode.xcu
@@ -93,6 +93,9 @@
<prop oor:name="HasNotebookbar">
<value>true</value>
</prop>
+ <prop oor:name="IsExperimental">
+ <value>true</value>
+ </prop>
<prop oor:name="MenuPosition">
<value>3</value>
</prop>
@@ -204,6 +207,9 @@
<prop oor:name="HasNotebookbar">
<value>true</value>
</prop>
+ <prop oor:name="IsExperimental">
+ <value>true</value>
+ </prop>
<prop oor:name="MenuPosition">
<value>3</value>
</prop>
@@ -290,6 +296,9 @@
<prop oor:name="HasNotebookbar">
<value>true</value>
</prop>
+ <prop oor:name="IsExperimental">
+ <value>true</value>
+ </prop>
<prop oor:name="MenuPosition">
<value>3</value>
</prop>
diff --git a/officecfg/registry/schema/org/openoffice/Office/UI/ToolbarMode.xcs b/officecfg/registry/schema/org/openoffice/Office/UI/ToolbarMode.xcs
index 4a2a5adc6282..50759f83d8ed 100644
--- a/officecfg/registry/schema/org/openoffice/Office/UI/ToolbarMode.xcs
+++ b/officecfg/registry/schema/org/openoffice/Office/UI/ToolbarMode.xcs
@@ -41,6 +41,11 @@
<desc>Position in the menu.</desc>
</info>
</prop>
+ <prop oor:name="IsExperimental" oor:type="xs:boolean" oor:nillable="true">
+ <info>
+ <desc>Enables entry only in the experimental mode.</desc>
+ </info>
+ </prop>
<prop oor:name="HasNotebookbar" oor:type="xs:boolean" oor:nillable="false">
<info>
<desc>Determines if Notebookbar is visible.</desc>