diff options
Diffstat (limited to 'framework')
-rw-r--r-- | framework/source/fwe/xml/menudocumenthandler.cxx | 8 |
1 files changed, 3 insertions, 5 deletions
diff --git a/framework/source/fwe/xml/menudocumenthandler.cxx b/framework/source/fwe/xml/menudocumenthandler.cxx index 9f48ff4ad901..ccb5b5a39fa6 100644 --- a/framework/source/fwe/xml/menudocumenthandler.cxx +++ b/framework/source/fwe/xml/menudocumenthandler.cxx @@ -76,8 +76,6 @@ static const char ITEM_DESCRIPTOR_TYPE[] = "Type"; static const char ITEM_DESCRIPTOR_STYLE[] = "Style"; // special popup menus (filled during runtime) must be saved as an empty popup menu or menuitem!!! -static const sal_Int32 CMD_PROTOCOL_SIZE = 5; -static const char CMD_PROTOCOL[] = ".uno:"; static const char ADDDIRECT_CMD[] = ".uno:AddDirect"; static const char AUTOPILOTMENU_CMD[] = ".uno:AutoPilotMenu"; @@ -814,7 +812,7 @@ throw ( SAXException, RuntimeException ) m_aAttributeType, aCommandURL ); - if ( aCommandURL.copy( CMD_PROTOCOL_SIZE ) != CMD_PROTOCOL ) + if ( !aLabel.isEmpty() ) pListMenu->AddAttribute( OUString( ATTRIBUTE_NS_LABEL ), m_aAttributeType, aLabel ); @@ -872,13 +870,13 @@ void OWriteMenuDocumentHandler::WriteMenuItem( const OUString& aCommandURL, cons aHelpURL ); } - if ( !aLabel.isEmpty() && aCommandURL.copy( CMD_PROTOCOL_SIZE ) != CMD_PROTOCOL ) + if ( !aLabel.isEmpty() ) { pList->AddAttribute( OUString( ATTRIBUTE_NS_LABEL ), m_aAttributeType, aLabel ); } - if (( nStyle > 0 ) && aCommandURL.copy( CMD_PROTOCOL_SIZE ) != CMD_PROTOCOL ) + if ( nStyle > 0 ) { OUString aValue; MenuStyleItem* pStyle = MenuItemStyles; |