summaryrefslogtreecommitdiff
path: root/framework
diff options
context:
space:
mode:
authorMaxim Monastirsky <momonasmon@gmail.com>2017-05-17 19:14:33 +0300
committerMaxim Monastirsky <momonasmon@gmail.com>2017-05-18 00:29:25 +0300
commitfb1814900590e3a6d60a877fdd897aa6b9aaba97 (patch)
tree2a433cb6fcdadc77144913bf68341d66b585c272 /framework
parentde67c7b13f984b10cd745510783298b110d63ab2 (diff)
Clean obsolete code from menu document writer
Remove special handling of New, Wizards, and Addon sub-menus. Many years ago they used to be injected into the menu structure at runtime, so we had to not write their contents back to xml. Now we have a clear separation between the contents of a menu at UNO API level, and the actual contents of the VCL menubar. Change-Id: I5e791e8963faca9f26ad31c9b4e6b8763b70d1d9
Diffstat (limited to 'framework')
-rw-r--r--framework/source/fwe/classes/addonmenu.cxx6
-rw-r--r--framework/source/fwe/xml/menudocumenthandler.cxx10
2 files changed, 1 insertions, 15 deletions
diff --git a/framework/source/fwe/classes/addonmenu.cxx b/framework/source/fwe/classes/addonmenu.cxx
index ebfcb0a494ae..4fd79253dafb 100644
--- a/framework/source/fwe/classes/addonmenu.cxx
+++ b/framework/source/fwe/classes/addonmenu.cxx
@@ -55,12 +55,6 @@ AddonMenu::~AddonMenu()
disposeOnce();
}
-// Check if command URL string has the unique prefix to identify addon popup menus
-bool AddonPopupMenu::IsCommandURLPrefix( const OUString& aCmdURL )
-{
- return aCmdURL.startsWith( ADDONSPOPUPMENU_URL_PREFIX_STR );
-}
-
AddonPopupMenu::AddonPopupMenu() :
AddonMenu()
{
diff --git a/framework/source/fwe/xml/menudocumenthandler.cxx b/framework/source/fwe/xml/menudocumenthandler.cxx
index ea6473771d77..a7d8bd0e1acf 100644
--- a/framework/source/fwe/xml/menudocumenthandler.cxx
+++ b/framework/source/fwe/xml/menudocumenthandler.cxx
@@ -22,7 +22,6 @@
#include <xml/menudocumenthandler.hxx>
#include <framework/menuconfiguration.hxx>
-#include <framework/addonmenu.hxx>
#include <com/sun/star/xml/sax/SAXException.hpp>
#include <com/sun/star/xml/sax/XExtendedDocumentHandler.hpp>
@@ -790,14 +789,7 @@ void OWriteMenuDocumentHandler::WriteMenu( const Reference< XIndexAccess >& rMen
ExtractMenuParameters( aProps, aCommandURL, aLabel, aHelpURL, xSubMenu, nType, nItemBits );
if ( xSubMenu.is() )
{
- // special popup menus (filled during runtime) must be saved as an empty popup menu or menuitem!!!
- if ( aCommandURL == ".uno:AddDirect" ||
- aCommandURL == ".uno:AutoPilotMenu" )
- {
- WriteMenuItem( aCommandURL, aLabel, aHelpURL, nItemBits );
- bSeparator = false;
- }
- else if ( !aCommandURL.isEmpty() && !AddonPopupMenu::IsCommandURLPrefix( aCommandURL ))
+ if ( !aCommandURL.isEmpty() )
{
::comphelper::AttributeList* pListMenu = new ::comphelper::AttributeList;
Reference< XAttributeList > xListMenu( static_cast<XAttributeList *>(pListMenu) , UNO_QUERY );