[Libreoffice-commits] .: 9 commits - basic/source desktop/source framework/inc framework/source

Caolán McNamara caolan at kemper.freedesktop.org
Sun Jan 16 08:43:48 PST 2011


 basic/source/runtime/runtime.cxx                    |    2 -
 basic/source/uno/namecont.cxx                       |   16 ++++----
 desktop/source/app/app.cxx                          |    7 ---
 framework/inc/dispatchcommands.h                    |    5 --
 framework/source/classes/menumanager.cxx            |   36 +++++++++---------
 framework/source/dispatch/dispatchprovider.cxx      |    2 -
 framework/source/dispatch/startmoduledispatcher.cxx |    2 -
 framework/source/inc/pattern/configuration.hxx      |    4 --
 framework/source/uielement/menubarmanager.cxx       |   39 ++++++++------------
 9 files changed, 48 insertions(+), 65 deletions(-)

New commits:
commit 0945629d19ceb915baeb735a30072a8691f9e8b6
Author: Caolán McNamara <caolanm at redhat.com>
Date:   Sun Jan 16 16:38:31 2011 +0000

    C4706 silence assign in comparison warning

diff --git a/basic/source/runtime/runtime.cxx b/basic/source/runtime/runtime.cxx
index ded4ba0..c10ef56 100644
--- a/basic/source/runtime/runtime.cxx
+++ b/basic/source/runtime/runtime.cxx
@@ -1043,7 +1043,7 @@ void SbiRuntime::TOSMakeTemp()
         p->Broadcast( SBX_HINT_DATAWANTED );
 
     SbxVariable* pDflt = NULL;
-    if ( bVBAEnabled &&  ( p->GetType() == SbxOBJECT || p->GetType() == SbxVARIANT  ) && ( pDflt = getDefaultProp( p ) ) )
+    if ( bVBAEnabled &&  ( p->GetType() == SbxOBJECT || p->GetType() == SbxVARIANT  ) && ((pDflt = getDefaultProp(p)) != NULL) )
     {
         pDflt->Broadcast( SBX_HINT_DATAWANTED );
         // replacing new p on stack causes object pointed by
commit 39efd30fd6a91ccdb676099783885bf8c3ed6788
Author: Caolán McNamara <caolanm at redhat.com>
Date:   Sun Jan 16 16:20:55 2011 +0000

    drop static and just use a single sal_Unicode

diff --git a/framework/source/inc/pattern/configuration.hxx b/framework/source/inc/pattern/configuration.hxx
index 73b4022..3b1d4d2 100644
--- a/framework/source/inc/pattern/configuration.hxx
+++ b/framework/source/inc/pattern/configuration.hxx
@@ -119,8 +119,6 @@ class ConfigurationHelper
                                                                       const ::rtl::OUString&                                        sRelPath  ,
                                                                             sal_Int32                                               nOpenFlags)
         {
-            static ::rtl::OUString PATH_SEPERATOR(RTL_CONSTASCII_USTRINGPARAM("/"));
-            
             css::uno::Reference< css::uno::XInterface > xCFG;
             
             try
@@ -130,7 +128,7 @@ class ConfigurationHelper
         
                 ::rtl::OUStringBuffer sPath(1024);
                 sPath.append(sPackage      );
-                sPath.append(PATH_SEPERATOR);
+                sPath.append(static_cast<sal_Unicode>('/'));
                 sPath.append(sRelPath      );
 
                 sal_Bool bReadOnly   = ((nOpenFlags & ConfigurationHelper::E_READONLY   ) == ConfigurationHelper::E_READONLY   ); 
commit fe03673ef14b0aae4e3f70cae3f8b246b3714df6
Author: Caolán McNamara <caolanm at redhat.com>
Date:   Sun Jan 16 16:11:26 2011 +0000

    drop unused strings

diff --git a/desktop/source/app/app.cxx b/desktop/source/app/app.cxx
index d4fab3f..1b4e53a 100644
--- a/desktop/source/app/app.cxx
+++ b/desktop/source/app/app.cxx
@@ -1235,8 +1235,6 @@ void impl_checkRecoveryState(sal_Bool& bCrashed           ,
     static const ::rtl::OUString PROP_CRASHED(RTL_CONSTASCII_USTRINGPARAM("Crashed"));
     static const ::rtl::OUString PROP_EXISTSRECOVERY(RTL_CONSTASCII_USTRINGPARAM("ExistsRecoveryData"));
     static const ::rtl::OUString PROP_EXISTSSESSION(RTL_CONSTASCII_USTRINGPARAM("ExistsSessionData"));
-    static const ::rtl::OUString CFG_PACKAGE_RECOVERY(RTL_CONSTASCII_USTRINGPARAM("org.openoffice.Office.Recovery/"));
-    static const ::rtl::OUString CFG_PATH_RECOVERYINFO(RTL_CONSTASCII_USTRINGPARAM("RecoveryInfo"));
 
     bCrashed            = sal_False;
     bRecoveryDataExists = sal_False;
commit a7585c06c15971a0256fc9b2758dac944220617d
Author: Caolán McNamara <caolanm at redhat.com>
Date:   Sun Jan 16 16:01:33 2011 +0000

    equalsAsciiL faster than equals

diff --git a/framework/source/uielement/menubarmanager.cxx b/framework/source/uielement/menubarmanager.cxx
index 07896af..53b2003 100644
--- a/framework/source/uielement/menubarmanager.cxx
+++ b/framework/source/uielement/menubarmanager.cxx
@@ -171,22 +171,17 @@ namespace framework
 
 #define SFX_REFERER_USER		"private:user"
 
-const ::rtl::OUString aCmdHelpIndex( RTL_CONSTASCII_USTRINGPARAM( ".uno:HelpIndex" ));
-const ::rtl::OUString aCmdToolsMenu( RTL_CONSTASCII_USTRINGPARAM( ".uno:ToolsMenu" ));
-const ::rtl::OUString aCmdHelpMenu( RTL_CONSTASCII_USTRINGPARAM( ".uno:HelpMenu" ));
-const ::rtl::OUString aSlotHelpMenu( RTL_CONSTASCII_USTRINGPARAM( "slot:5410" ));
+#define aCmdHelpIndex ".uno:HelpIndex"
+#define aCmdToolsMenu ".uno:ToolsMenu"
+#define aCmdHelpMenu ".uno:HelpMenu"
+#define aSlotHelpMenu "slot:5410"
 
-const ::rtl::OUString aSpecialFileMenu( RTL_CONSTASCII_USTRINGPARAM( "file" ));
-const ::rtl::OUString aSpecialWindowMenu( RTL_CONSTASCII_USTRINGPARAM( "window" ));
-const ::rtl::OUString aSlotSpecialFileMenu( RTL_CONSTASCII_USTRINGPARAM( "slot:5510" ));
-const ::rtl::OUString aSlotSpecialWindowMenu( RTL_CONSTASCII_USTRINGPARAM( "slot:5610" ));
-const ::rtl::OUString aSlotSpecialToolsMenu( RTL_CONSTASCII_USTRINGPARAM( "slot:6677" ));
+#define aSpecialWindowMenu "window"
+#define aSlotSpecialWindowMenu "slot:5610"
+#define aSlotSpecialToolsMenu "slot:6677"
 
-// special uno commands for picklist and window list
-const ::rtl::OUString aSpecialFileCommand( RTL_CONSTASCII_USTRINGPARAM( ".uno:PickList" ));
-const ::rtl::OUString aSpecialWindowCommand( RTL_CONSTASCII_USTRINGPARAM( ".uno:WindowList" ));
-
-const ::rtl::OUString UNO_COMMAND( RTL_CONSTASCII_USTRINGPARAM( ".uno:" ));
+// special uno commands for window list
+#define aSpecialWindowCommand ".uno:WindowList"
 
 static sal_Int16 getImageTypeFromBools( sal_Bool bBig )
 {
@@ -861,9 +856,9 @@ IMPL_LINK( MenuBarManager, Activate, Menu *, pMenu )
         m_bActive = TRUE;
 
         ::rtl::OUString aMenuCommand( m_aMenuItemCommand );
-        if ( m_aMenuItemCommand == aSpecialWindowMenu ||
-             m_aMenuItemCommand == aSlotSpecialWindowMenu ||
-             aMenuCommand == aSpecialWindowCommand )
+        if ( m_aMenuItemCommand.equalsAsciiL(RTL_CONSTASCII_STRINGPARAM(aSpecialWindowMenu)) ||
+             m_aMenuItemCommand.equalsAsciiL(RTL_CONSTASCII_STRINGPARAM(aSlotSpecialWindowMenu)) ||
+             aMenuCommand.equalsAsciiL(RTL_CONSTASCII_STRINGPARAM(aSpecialWindowCommand)) )
              MenuManager::UpdateSpecialWindowMenu( pMenu,getServiceFactory(),m_aLock );
 
         // Check if some modes have changed so we have to update our menu images
@@ -902,7 +897,7 @@ IMPL_LINK( MenuBarManager, Activate, Menu *, pMenu )
 
                 // Set key code, workaround for hard-coded shortcut F1 mapped to .uno:HelpIndex
                 // Only non-popup menu items can have a short-cut
-                if ( pMenuItemHandler->aMenuItemURL == aCmdHelpIndex )
+                if ( pMenuItemHandler->aMenuItemURL.equalsAsciiL(RTL_CONSTASCII_STRINGPARAM(aCmdHelpIndex)) )
                 {
                     KeyCode aKeyCode( KEY_F1 );
                     pMenu->SetAccelKey( pMenuItemHandler->nItemId, aKeyCode );
@@ -1277,7 +1272,7 @@ void MenuBarManager::FillMenuManager( Menu* pMenu, const Reference< XFrame >& rF
             USHORT          nItemId  = pMenu->GetItemId( nPos );
             ::rtl::OUString aCommand = pMenu->GetItemCommand( nItemId );
             if ( nItemId == SID_MDIWINDOWLIST ||
-                 aCommand == aSpecialWindowCommand )
+                 aCommand.equalsAsciiL(RTL_CONSTASCII_STRINGPARAM(aSpecialWindowCommand)) )
             {
                 // Retrieve addon popup menus and add them to our menu bar
                 Reference< com::sun::star::frame::XModel >		xModel;
@@ -1378,12 +1373,12 @@ void MenuBarManager::FillMenuManager( Menu* pMenu, const Reference< XFrame >& rF
                     xPopupMenuDispatchProvider = pAttributes->xDispatchProvider;
 
                 // Check if this is the help menu. Add menu item if needed
-                if ( nItemId == SID_HELPMENU || aItemCommand == aSlotHelpMenu || aItemCommand == aCmdHelpMenu )
+                if ( nItemId == SID_HELPMENU || aItemCommand.equalsAsciiL(RTL_CONSTASCII_STRINGPARAM(aSlotHelpMenu)) || aItemCommand.equalsAsciiL(RTL_CONSTASCII_STRINGPARAM(aCmdHelpMenu)) )
                 {
                     // Check if this is the help menu. Add menu item if needed
                     CheckAndAddMenuExtension( pPopup );
                 }
-                else if (( nItemId == SID_ADDONLIST || aItemCommand == aSlotSpecialToolsMenu || aItemCommand == aCmdToolsMenu ) &&
+                else if (( nItemId == SID_ADDONLIST || aItemCommand.equalsAsciiL(RTL_CONSTASCII_STRINGPARAM(aSlotSpecialToolsMenu)) || aItemCommand.equalsAsciiL(RTL_CONSTASCII_STRINGPARAM(aCmdToolsMenu)) ) &&
                          AddonMenuManager::HasAddonMenuElements() )
                 {
                     // Create addon popup menu if there exist elements and this is the tools popup menu
@@ -1508,7 +1503,7 @@ void MenuBarManager::FillMenuManager( Menu* pMenu, const Reference< XFrame >& rF
 
             // Set key code, workaround for hard-coded shortcut F1 mapped to .uno:HelpIndex
             // Only non-popup menu items can have a short-cut
-            if ( pMenuItemHandler->aMenuItemURL == aCmdHelpIndex )
+            if ( pMenuItemHandler->aMenuItemURL.equalsAsciiL(RTL_CONSTASCII_STRINGPARAM(aCmdHelpIndex)) )
             {
                 KeyCode aKeyCode( KEY_F1 );
                 pMenu->SetAccelKey( pMenuItemHandler->nItemId, aKeyCode );
commit 55f5aeacd186b1f783c6018ec16d70ae7ce12cc8
Author: Caolán McNamara <caolanm at redhat.com>
Date:   Sun Jan 16 15:56:59 2011 +0000

    equalsAsciiL faster than equals

diff --git a/framework/source/classes/menumanager.cxx b/framework/source/classes/menumanager.cxx
index 49a4efa..9cde97e 100644
--- a/framework/source/classes/menumanager.cxx
+++ b/framework/source/classes/menumanager.cxx
@@ -119,18 +119,18 @@ namespace framework
 
 #define SFX_REFERER_USER		"private:user"
 
-const ::rtl::OUString aSlotNewDocDirect( RTL_CONSTASCII_USTRINGPARAM( "slot:5537" ));
-const ::rtl::OUString aSlotAutoPilot( RTL_CONSTASCII_USTRINGPARAM( "slot:6381" ));
+#define aSlotNewDocDirect "slot:5537"
+#define aSlotAutoPilot "slot:6381"
 
-const ::rtl::OUString aSpecialFileMenu( RTL_CONSTASCII_USTRINGPARAM( "file" ));
-const ::rtl::OUString aSpecialWindowMenu( RTL_CONSTASCII_USTRINGPARAM( "window" ));
-const ::rtl::OUString aSlotSpecialFileMenu( RTL_CONSTASCII_USTRINGPARAM( "slot:5510" ));
-const ::rtl::OUString aSlotSpecialWindowMenu( RTL_CONSTASCII_USTRINGPARAM( "slot:5610" ));
-const ::rtl::OUString aSlotSpecialToolsMenu( RTL_CONSTASCII_USTRINGPARAM( "slot:6677" ));
+#define aSpecialFileMenu "file"
+#define aSpecialWindowMenu "window"
+#define aSlotSpecialFileMenu "slot:5510"
+#define aSlotSpecialWindowMenu "slot:5610"
+#define aSlotSpecialToolsMenu "slot:6677"
 
 // special uno commands for picklist and window list
-const ::rtl::OUString aSpecialFileCommand( RTL_CONSTASCII_USTRINGPARAM( "PickList" ));
-const ::rtl::OUString aSpecialWindowCommand( RTL_CONSTASCII_USTRINGPARAM( "WindowList" ));
+#define aSpecialFileCommand "PickList"
+#define aSpecialWindowCommand "WindowList"
 
 const ::rtl::OUString UNO_COMMAND( RTL_CONSTASCII_USTRINGPARAM( ".uno:" ));
 
@@ -184,7 +184,7 @@ MenuManager::MenuManager(
 
                 // Create addon popup menu if there exist elements and this is the tools popup menu
                 if (( nItemId == SID_ADDONLIST ||
-                    aItemCommand == aSlotSpecialToolsMenu ) &&
+                    aItemCommand.equalsAsciiL(RTL_CONSTASCII_STRINGPARAM(aSlotSpecialToolsMenu)) ) &&
                     AddonMenuManager::HasAddonMenuElements() )
                 {
                     USHORT      nCount   = 0;
@@ -224,7 +224,7 @@ MenuManager::MenuManager(
         else
         {
             if ( nItemId == SID_NEWDOCDIRECT ||
-                 aItemCommand == aSlotNewDocDirect )
+                 aItemCommand.equalsAsciiL(RTL_CONSTASCII_STRINGPARAM(aSlotNewDocDirect)) )
             {
                 // #110897#
                 // Reference< ::com::sun::star::lang::XMultiServiceFactory > aMultiServiceFactory(::comphelper::getProcessServiceFactory());
@@ -244,7 +244,7 @@ MenuManager::MenuManager(
                 }
             }
             else if ( nItemId == SID_AUTOPILOTMENU ||
-                      aItemCommand == aSlotAutoPilot )
+                      aItemCommand.equalsAsciiL(RTL_CONSTASCII_STRINGPARAM(aSlotAutoPilot)) )
             {
                 // #110897#
                 // Reference< ::com::sun::star::lang::XMultiServiceFactory > aMultiServiceFactory(::comphelper::getProcessServiceFactory());
@@ -813,13 +813,13 @@ IMPL_LINK( MenuManager, Activate, Menu *, pMenu )
             aCommand = aCommand.copy( UNO_COMMAND.getLength() );
         }
 
-        if ( m_aMenuItemCommand == aSpecialFileMenu ||
-             m_aMenuItemCommand == aSlotSpecialFileMenu ||
-             aCommand == aSpecialFileCommand )
+        if ( m_aMenuItemCommand.equalsAsciiL(RTL_CONSTASCII_STRINGPARAM(aSpecialFileMenu)) ||
+             m_aMenuItemCommand.equalsAsciiL(RTL_CONSTASCII_STRINGPARAM(aSlotSpecialFileMenu)) ||
+             aCommand.equalsAsciiL(RTL_CONSTASCII_STRINGPARAM(aSpecialFileCommand)) )
             UpdateSpecialFileMenu( pMenu );
-        else if ( m_aMenuItemCommand == aSpecialWindowMenu ||
-                  m_aMenuItemCommand == aSlotSpecialWindowMenu ||
-                  aCommand == aSpecialWindowCommand )
+        else if ( m_aMenuItemCommand.equalsAsciiL(RTL_CONSTASCII_STRINGPARAM(aSpecialWindowMenu)) ||
+                  m_aMenuItemCommand.equalsAsciiL(RTL_CONSTASCII_STRINGPARAM(aSlotSpecialWindowMenu)) ||
+                  aCommand.equalsAsciiL(RTL_CONSTASCII_STRINGPARAM(aSpecialWindowCommand)) )
                   UpdateSpecialWindowMenu( pMenu,getServiceFactory(),m_aLock );
 
         // Check if some modes have changed so we have to update our menu images
commit dcdeb0993f78c722cbba99780746932d285eb313
Author: Caolán McNamara <caolanm at redhat.com>
Date:   Sun Jan 16 15:48:11 2011 +0000

    equalsAsciiL faster than equals

diff --git a/framework/inc/dispatchcommands.h b/framework/inc/dispatchcommands.h
index f155de3..0084610 100644
--- a/framework/inc/dispatchcommands.h
+++ b/framework/inc/dispatchcommands.h
@@ -43,7 +43,7 @@ namespace framework{
 
 //_________________________________________________________________________________________________________________
 
-static ::rtl::OUString CMD_UNO_SHOWSTARTMODULE(RTL_CONSTASCII_USTRINGPARAM(".uno:ShowStartModule"));
+#define CMD_UNO_SHOWSTARTMODULE ".uno:ShowStartModule"
 
 }		//	namespace framework
 
diff --git a/framework/source/dispatch/dispatchprovider.cxx b/framework/source/dispatch/dispatchprovider.cxx
index 5d07307..2b4a73d 100644
--- a/framework/source/dispatch/dispatchprovider.cxx
+++ b/framework/source/dispatch/dispatchprovider.cxx
@@ -226,7 +226,7 @@ css::uno::Sequence< css::uno::Reference< css::frame::XDispatch > > SAL_CALL Disp
 
 ::sal_Bool lcl_isStartModuleDispatch (const css::util::URL& aURL)
 {
-    return (aURL.Complete.equals(CMD_UNO_SHOWSTARTMODULE));
+    return (aURL.Complete.equalsAsciiL(RTL_CONSTASCII_STRINGPARAM(CMD_UNO_SHOWSTARTMODULE)));
 }
 
 //_________________________________________________________________________________________________________________
diff --git a/framework/source/dispatch/startmoduledispatcher.cxx b/framework/source/dispatch/startmoduledispatcher.cxx
index 441c5be..d201fab 100644
--- a/framework/source/dispatch/startmoduledispatcher.cxx
+++ b/framework/source/dispatch/startmoduledispatcher.cxx
@@ -120,7 +120,7 @@ void SAL_CALL StartModuleDispatcher::dispatchWithNotification(const css::util::U
     throw(css::uno::RuntimeException)
 {
     ::sal_Int16 nResult = css::frame::DispatchResultState::DONTKNOW;
-    if (aURL.Complete.equals (CMD_UNO_SHOWSTARTMODULE))
+    if (aURL.Complete.equalsAsciiL(RTL_CONSTASCII_STRINGPARAM(CMD_UNO_SHOWSTARTMODULE)))
     {
         nResult = css::frame::DispatchResultState::FAILURE;
         if (implts_isBackingModePossible ())
commit 181c8e131c0fd584f252df02c59bbbe6bfb1cda9
Author: Caolán McNamara <caolanm at redhat.com>
Date:   Sun Jan 16 15:46:21 2011 +0000

    remove unused strings

diff --git a/framework/inc/dispatchcommands.h b/framework/inc/dispatchcommands.h
index 7ddb4fc..f155de3 100644
--- a/framework/inc/dispatchcommands.h
+++ b/framework/inc/dispatchcommands.h
@@ -44,9 +44,6 @@ namespace framework{
 //_________________________________________________________________________________________________________________
 
 static ::rtl::OUString CMD_UNO_SHOWSTARTMODULE(RTL_CONSTASCII_USTRINGPARAM(".uno:ShowStartModule"));
-static ::rtl::OUString CMD_UNO_CLOSEDOC(RTL_CONSTASCII_USTRINGPARAM(".uno:CloseDoc"));
-static ::rtl::OUString CMD_UNO_CLOSEWIN(RTL_CONSTASCII_USTRINGPARAM(".uno:CloseWin"));
-static ::rtl::OUString CMD_UNO_CLOSEFRAME(RTL_CONSTASCII_USTRINGPARAM(".uno:CloseFrame"));
 
 }		//	namespace framework
 
commit 86065485796d67cac71386dbc5a796da0fbcae01
Author: Caolán McNamara <caolanm at redhat.com>
Date:   Sun Jan 16 15:35:13 2011 +0000

    equalsAsciiL faster than equals

diff --git a/basic/source/uno/namecont.cxx b/basic/source/uno/namecont.cxx
index 140fdaf..067b8c9 100644
--- a/basic/source/uno/namecont.cxx
+++ b/basic/source/uno/namecont.cxx
@@ -3118,8 +3118,8 @@ void SAL_CALL SfxLibrary::removeContainerListener( const Reference< XContainerLi
 //============================================================================
 // Implementation class ScriptExtensionIterator
 
-static rtl::OUString aBasicLibMediaType(RTL_CONSTASCII_USTRINGPARAM("application/vnd.sun.star.basic-library"));
-static rtl::OUString aDialogLibMediaType(RTL_CONSTASCII_USTRINGPARAM("application/vnd.sun.star.dialog-library"));
+#define sBasicLibMediaType "application/vnd.sun.star.basic-library"
+#define sDialogLibMediaType "application/vnd.sun.star.dialog-library"
 
 ScriptExtensionIterator::ScriptExtensionIterator( void )
     : m_eState( USER_EXTENSIONS )
@@ -3270,11 +3270,11 @@ Reference< deployment::XPackage > ScriptSubPackageIterator::implDetectScriptPack
     {
         const Reference< deployment::XPackageTypeInfo > xPackageTypeInfo = xPackage->getPackageType();
         rtl::OUString aMediaType = xPackageTypeInfo->getMediaType();
-        if( aMediaType.equals( aBasicLibMediaType ) )
+        if( aMediaType.equalsAsciiL(RTL_CONSTASCII_STRINGPARAM(sBasicLibMediaType)) )
         {
             xScriptPackage = xPackage;
         }
-        else if( aMediaType.equals( aDialogLibMediaType ) )
+        else if( aMediaType.equalsAsciiL(RTL_CONSTASCII_STRINGPARAM(sDialogLibMediaType)) )
         {
             rbPureDialogLib = true;
             xScriptPackage = xPackage;
@@ -3316,12 +3316,12 @@ Reference< deployment::XPackage > ScriptExtensionIterator::implGetScriptPackageF
                 const Reference< deployment::XPackage > xSubPkg = pSeq[ iPkg ];
                 const Reference< deployment::XPackageTypeInfo > xPackageTypeInfo = xSubPkg->getPackageType();
                 rtl::OUString aMediaType = xPackageTypeInfo->getMediaType();
-                if( aMediaType.equals( aBasicLibMediaType ) )
+                if( aMediaType.equalsAsciiL(RTL_CONSTASCII_STRINGPARAM(sBasicLibMediaType)) )
                 {
                     xScriptPackage = xSubPkg;
                     break;
                 }
-                else if( aMediaType.equals( aDialogLibMediaType ) )
+                else if( aMediaType.equalsAsciiL(RTL_CONSTASCII_STRINGPARAM(sDialogLibMediaType)) )
                 {
                     rbPureDialogLib = true;
                     xScriptPackage = xSubPkg;
@@ -3333,11 +3333,11 @@ Reference< deployment::XPackage > ScriptExtensionIterator::implGetScriptPackageF
         {
             const Reference< deployment::XPackageTypeInfo > xPackageTypeInfo = xPackage->getPackageType();
             rtl::OUString aMediaType = xPackageTypeInfo->getMediaType();
-            if( aMediaType.equals( aBasicLibMediaType ) )
+            if( aMediaType.equalsAsciiL(RTL_CONSTASCII_STRINGPARAM(sBasicLibMediaType)) )
             {
                 xScriptPackage = xPackage;
             }
-            else if( aMediaType.equals( aDialogLibMediaType ) )
+            else if( aMediaType.equalsAsciiL(RTL_CONSTASCII_STRINGPARAM(sDialogLibMediaType)) )
             {
                 rbPureDialogLib = true;
                 xScriptPackage = xPackage;
commit 9a8405256bb6737e7f11c5e0edb395e344df8720
Author: Caolán McNamara <caolanm at redhat.com>
Date:   Sun Jan 16 15:34:44 2011 +0000

    drop unused global OUStrings

diff --git a/desktop/source/app/app.cxx b/desktop/source/app/app.cxx
index 36c8f66..d4fab3f 100644
--- a/desktop/source/app/app.cxx
+++ b/desktop/source/app/app.cxx
@@ -189,11 +189,6 @@ namespace desktop
 static oslSignalHandler pSignalHandler = 0;
 static sal_Bool _bCrashReporterEnabled = sal_True;
 
-static const ::rtl::OUString CFG_PACKAGE_COMMON_HELP   ( RTL_CONSTASCII_USTRINGPARAM( "org.openoffice.Office.Common/Help"));
-static const ::rtl::OUString CFG_PATH_REG              ( RTL_CONSTASCII_USTRINGPARAM( "Registration"                     ));
-static const ::rtl::OUString CFG_ENTRY_REGURL          ( RTL_CONSTASCII_USTRINGPARAM( "URL"                              ));
-static const ::rtl::OUString CFG_ENTRY_TEMPLATEREGURL  ( RTL_CONSTASCII_USTRINGPARAM( "TemplateURL"                      ));
-
 // ----------------------------------------------------------------------------
 
 ResMgr* Desktop::GetDesktopResManager()


More information about the Libreoffice-commits mailing list