diff options
author | Thomas Arnhold <thomas@arnhold.org> | 2011-01-20 11:23:45 +0100 |
---|---|---|
committer | Thomas Arnhold <thomas@arnhold.org> | 2011-01-20 11:23:45 +0100 |
commit | 898c3aa0f57dfdad973b1c9fe3a3e81bb63cbadc (patch) | |
tree | ab5c66bc8ef5915180054520d9d229f40c5b90f3 /framework | |
parent | 4aa145a9fed5f1b1aec6ef3dfe64c67300c74a19 (diff) |
Replace suitable equalsAscii calls with equalsAsciiL.
Done with sed -i 's%\(\.equalsAscii\)(\(\s\?"[^"]\+"\)\(\s\?\))%\1L(\3RTL_CONSTASCII_STRINGPARAM(\2\3)\3)%g'.
Diffstat (limited to 'framework')
16 files changed, 46 insertions, 46 deletions
diff --git a/framework/source/accelerators/keymapping.cxx b/framework/source/accelerators/keymapping.cxx index 9d0a16d5e1..c5effdcb82 100644 --- a/framework/source/accelerators/keymapping.cxx +++ b/framework/source/accelerators/keymapping.cxx @@ -227,7 +227,7 @@ sal_Bool KeyMapping::impl_st_interpretIdentifierAsPureKeyCode(const ::rtl::OUStr // 0 is normaly an error of the called method toInt32() ... // But we must be aware, that the identifier is "0"! rCode = 0; - return sIdentifier.equalsAscii("0"); + return sIdentifier.equalsAsciiL(RTL_CONSTASCII_STRINGPARAM("0")); } } // namespace framework diff --git a/framework/source/classes/fwktabwindow.cxx b/framework/source/classes/fwktabwindow.cxx index e6b4575f29..f163f9156c 100644 --- a/framework/source/classes/fwktabwindow.cxx +++ b/framework/source/classes/fwktabwindow.cxx @@ -352,17 +352,17 @@ FwkTabPage* FwkTabWindow::AddTabPage( sal_Int32 nIndex, const uno::Sequence< bea beans::NamedValue aValue = rProperties[i]; ::rtl::OUString sName = aValue.Name; - if ( sName.equalsAscii("Title") ) + if ( sName.equalsAsciiL(RTL_CONSTASCII_STRINGPARAM("Title")) ) aValue.Value >>= sTitle; - else if ( sName.equalsAscii("ToolTip") ) + else if ( sName.equalsAsciiL(RTL_CONSTASCII_STRINGPARAM("ToolTip")) ) aValue.Value >>= sToolTip; - else if ( sName.equalsAscii("PageURL") ) + else if ( sName.equalsAsciiL(RTL_CONSTASCII_STRINGPARAM("PageURL")) ) aValue.Value >>= sPageURL; - else if ( sName.equalsAscii("EventHdl") ) + else if ( sName.equalsAsciiL(RTL_CONSTASCII_STRINGPARAM("EventHdl")) ) aValue.Value >>= xEventHdl; - else if ( sName.equalsAscii("Image") ) + else if ( sName.equalsAsciiL(RTL_CONSTASCII_STRINGPARAM("Image")) ) aValue.Value >>= xImage; - else if ( sName.equalsAscii("Disabled") ) + else if ( sName.equalsAsciiL(RTL_CONSTASCII_STRINGPARAM("Disabled")) ) aValue.Value >>= bDisabled; } diff --git a/framework/source/dispatch/closedispatcher.cxx b/framework/source/dispatch/closedispatcher.cxx index 4b7695a55a..e877111720 100644 --- a/framework/source/dispatch/closedispatcher.cxx +++ b/framework/source/dispatch/closedispatcher.cxx @@ -238,7 +238,7 @@ void SAL_CALL CloseDispatcher::dispatchWithNotification(const css::util::URL& sal_Bool bIsSynchron = sal_False; for (sal_Int32 nArgs=0; nArgs<lArguments.getLength(); nArgs++ ) { - if ( lArguments[nArgs].Name.equalsAscii("SynchronMode") ) + if ( lArguments[nArgs].Name.equalsAsciiL(RTL_CONSTASCII_STRINGPARAM("SynchronMode")) ) { lArguments[nArgs].Value >>= bIsSynchron; break; diff --git a/framework/source/helper/uielementwrapperbase.cxx b/framework/source/helper/uielementwrapperbase.cxx index 54c3bd2a67..9977eceaf9 100644 --- a/framework/source/helper/uielementwrapperbase.cxx +++ b/framework/source/helper/uielementwrapperbase.cxx @@ -137,9 +137,9 @@ throw ( Exception, RuntimeException ) PropertyValue aPropValue; if ( aArguments[n] >>= aPropValue ) { - if ( aPropValue.Name.equalsAscii( "ResourceURL" )) + if ( aPropValue.Name.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "ResourceURL" ) )) aPropValue.Value >>= m_aResourceURL; - else if ( aPropValue.Name.equalsAscii( "Frame" )) + else if ( aPropValue.Name.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "Frame" ) )) { Reference< XFrame > xFrame; aPropValue.Value >>= xFrame; diff --git a/framework/source/services/sessionlistener.cxx b/framework/source/services/sessionlistener.cxx index 0d94810f6d..0d65e2ed37 100644 --- a/framework/source/services/sessionlistener.cxx +++ b/framework/source/services/sessionlistener.cxx @@ -224,11 +224,11 @@ void SAL_CALL SessionListener::initialize(const Sequence< Any >& args) { if (args[i] >>= v) { - if (v.Name.equalsAscii("SessionManagerName")) + if (v.Name.equalsAsciiL(RTL_CONSTASCII_STRINGPARAM("SessionManagerName"))) v.Value >>= aSMgr; - else if (v.Name.equalsAscii("SessionManager")) + else if (v.Name.equalsAsciiL(RTL_CONSTASCII_STRINGPARAM("SessionManager"))) v.Value >>= m_rSessionManager; - else if (v.Name.equalsAscii("AllowUserInteractionOnQuit")) + else if (v.Name.equalsAsciiL(RTL_CONSTASCII_STRINGPARAM("AllowUserInteractionOnQuit"))) v.Value >>= m_bAllowUserInteractionOnQuit; } } @@ -246,14 +246,14 @@ void SAL_CALL SessionListener::initialize(const Sequence< Any >& args) void SAL_CALL SessionListener::statusChanged(const FeatureStateEvent& event) throw (css::uno::RuntimeException) { - if (event.FeatureURL.Complete.equalsAscii("vnd.sun.star.autorecovery:/doSessionRestore")) + if (event.FeatureURL.Complete.equalsAsciiL(RTL_CONSTASCII_STRINGPARAM("vnd.sun.star.autorecovery:/doSessionRestore"))) { if (event.FeatureDescriptor.compareToAscii("update")==0) m_bRestored = sal_True; // a document was restored // if (event.FeatureDescriptor.compareToAscii("stop")==0) } - else if (event.FeatureURL.Complete.equalsAscii("vnd.sun.star.autorecovery:/doSessionSave")) + else if (event.FeatureURL.Complete.equalsAsciiL(RTL_CONSTASCII_STRINGPARAM("vnd.sun.star.autorecovery:/doSessionSave"))) { if (event.FeatureDescriptor.compareToAscii("stop")==0) { diff --git a/framework/source/uielement/addonstoolbarwrapper.cxx b/framework/source/uielement/addonstoolbarwrapper.cxx index 93c5d46c77..2a4310bf04 100644 --- a/framework/source/uielement/addonstoolbarwrapper.cxx +++ b/framework/source/uielement/addonstoolbarwrapper.cxx @@ -124,7 +124,7 @@ void SAL_CALL AddonsToolBarWrapper::initialize( const Sequence< Any >& aArgument PropertyValue aPropValue; if ( aArguments[n] >>= aPropValue ) { - if ( aPropValue.Name.equalsAscii( "ConfigurationData" )) + if ( aPropValue.Name.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "ConfigurationData" ) )) aPropValue.Value >>= m_aConfigData; } } diff --git a/framework/source/uielement/buttontoolbarcontroller.cxx b/framework/source/uielement/buttontoolbarcontroller.cxx index 6832a5ddcb..c2b8e48228 100644 --- a/framework/source/uielement/buttontoolbarcontroller.cxx +++ b/framework/source/uielement/buttontoolbarcontroller.cxx @@ -152,11 +152,11 @@ throw (::com::sun::star::uno::Exception, ::com::sun::star::uno::RuntimeException { if ( aArguments[i] >>= aPropValue ) { - if ( aPropValue.Name.equalsAscii( "Frame" )) + if ( aPropValue.Name.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "Frame" ) )) m_xFrame.set(aPropValue.Value,UNO_QUERY); - else if ( aPropValue.Name.equalsAscii( "CommandURL" )) + else if ( aPropValue.Name.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "CommandURL" ) )) aPropValue.Value >>= m_aCommandURL; - else if ( aPropValue.Name.equalsAscii( "ServiceManager" )) + else if ( aPropValue.Name.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "ServiceManager" ) )) m_xServiceManager.set(aPropValue.Value,UNO_QUERY); } } diff --git a/framework/source/uielement/constitemcontainer.cxx b/framework/source/uielement/constitemcontainer.cxx index e84382efe9..0b99dbd9f6 100644 --- a/framework/source/uielement/constitemcontainer.cxx +++ b/framework/source/uielement/constitemcontainer.cxx @@ -220,7 +220,7 @@ ConstItemContainer::ConstItemContainer( const Reference< XIndexAccess >& rSource Reference< XIndexAccess > xIndexAccess; for ( sal_Int32 j = 0; j < aPropSeq.getLength(); j++ ) { - if ( aPropSeq[j].Name.equalsAscii( "ItemDescriptorContainer" )) + if ( aPropSeq[j].Name.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "ItemDescriptorContainer" ) )) { aPropSeq[j].Value >>= xIndexAccess; nContainerIndex = j; @@ -257,7 +257,7 @@ void ConstItemContainer::copyItemContainer( const std::vector< Sequence< Propert Reference< XIndexAccess > xIndexAccess; for ( sal_Int32 j = 0; j < aPropSeq.getLength(); j++ ) { - if ( aPropSeq[j].Name.equalsAscii( "ItemDescriptorContainer" )) + if ( aPropSeq[j].Name.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "ItemDescriptorContainer" ) )) { aPropSeq[j].Value >>= xIndexAccess; nContainerIndex = j; diff --git a/framework/source/uielement/fontsizemenucontroller.cxx b/framework/source/uielement/fontsizemenucontroller.cxx index 707ed861c3..fbfcba7740 100644 --- a/framework/source/uielement/fontsizemenucontroller.cxx +++ b/framework/source/uielement/fontsizemenucontroller.cxx @@ -111,7 +111,7 @@ rtl::OUString FontSizeMenuController::retrievePrinterName( com::sun::star::uno:: Sequence< PropertyValue > aPrinterSeq = xPrintable->getPrinter(); for ( int i = 0; i < aPrinterSeq.getLength(); i++ ) { - if ( aPrinterSeq[i].Name.equalsAscii( "Name" )) + if ( aPrinterSeq[i].Name.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "Name" ) )) { aPrinterSeq[i].Value >>= aPrinterName; break; diff --git a/framework/source/uielement/itemcontainer.cxx b/framework/source/uielement/itemcontainer.cxx index caa6dc39a6..9b6c20c3e0 100644 --- a/framework/source/uielement/itemcontainer.cxx +++ b/framework/source/uielement/itemcontainer.cxx @@ -82,7 +82,7 @@ ItemContainer::ItemContainer( const Reference< XIndexAccess >& rSourceContainer, Reference< XIndexAccess > xIndexAccess; for ( sal_Int32 j = 0; j < aPropSeq.getLength(); j++ ) { - if ( aPropSeq[j].Name.equalsAscii( "ItemDescriptorContainer" )) + if ( aPropSeq[j].Name.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "ItemDescriptorContainer" ) )) { aPropSeq[j].Value >>= xIndexAccess; nContainerIndex = j; @@ -118,7 +118,7 @@ void ItemContainer::copyItemContainer( const std::vector< Sequence< PropertyValu Reference< XIndexAccess > xIndexAccess; for ( sal_Int32 j = 0; j < aPropSeq.getLength(); j++ ) { - if ( aPropSeq[j].Name.equalsAscii( "ItemDescriptorContainer" )) + if ( aPropSeq[j].Name.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "ItemDescriptorContainer" ) )) { aPropSeq[j].Value >>= xIndexAccess; nContainerIndex = j; diff --git a/framework/source/uielement/langselectionmenucontroller.cxx b/framework/source/uielement/langselectionmenucontroller.cxx index 64a01a65f5..e6510bef9b 100644 --- a/framework/source/uielement/langselectionmenucontroller.cxx +++ b/framework/source/uielement/langselectionmenucontroller.cxx @@ -335,15 +335,15 @@ void SAL_CALL LanguageSelectionMenuController::updatePopupMenu() throw ( ::com:: // TODO: Fill menu with the information retrieved by the status update - if( m_aCommandURL.equalsAscii( ".uno:SetLanguageSelectionMenu" )) + if( m_aCommandURL.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( ".uno:SetLanguageSelectionMenu" ) )) { fillPopupMenu(m_xPopupMenu, MODE_SetLanguageSelectionMenu ); } - else if( m_aCommandURL.equalsAscii( ".uno:SetLanguageParagraphMenu" )) + else if( m_aCommandURL.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( ".uno:SetLanguageParagraphMenu" ) )) { fillPopupMenu(m_xPopupMenu, MODE_SetLanguageParagraphMenu ); } - else if( m_aCommandURL.equalsAscii( ".uno:SetLanguageAllTextMenu" )) + else if( m_aCommandURL.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( ".uno:SetLanguageAllTextMenu" ) )) { fillPopupMenu(m_xPopupMenu, MODE_SetLanguageAllTextMenu ); } diff --git a/framework/source/uielement/newmenucontroller.cxx b/framework/source/uielement/newmenucontroller.cxx index f13926339e..77fa03d86f 100644 --- a/framework/source/uielement/newmenucontroller.cxx +++ b/framework/source/uielement/newmenucontroller.cxx @@ -521,7 +521,7 @@ void NewMenuController::impl_setPopupMenu() { for ( sal_Int32 y = 0; y < aSeq.getLength(); y++ ) { - if ( aSeq[y].Name.equalsAscii("ooSetupFactoryEmptyDocumentURL") ) + if ( aSeq[y].Name.equalsAsciiL(RTL_CONSTASCII_STRINGPARAM("ooSetupFactoryEmptyDocumentURL")) ) { aSeq[y].Value >>= m_aEmptyDocURL; break; @@ -555,7 +555,7 @@ void SAL_CALL NewMenuController::initialize( const Sequence< Any >& aArguments ) const StyleSettings& rSettings = Application::GetSettings().GetStyleSettings(); m_bShowImages = rSettings.GetUseImagesInMenus(); - m_bNewMenu = m_aCommandURL.equalsAscii( ".uno:AddDirect" ); + m_bNewMenu = m_aCommandURL.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( ".uno:AddDirect" ) ); } } } diff --git a/framework/source/uielement/rootitemcontainer.cxx b/framework/source/uielement/rootitemcontainer.cxx index 9c65e0c844..75a308b906 100644 --- a/framework/source/uielement/rootitemcontainer.cxx +++ b/framework/source/uielement/rootitemcontainer.cxx @@ -145,7 +145,7 @@ RootItemContainer::RootItemContainer( const Reference< XIndexAccess >& rSourceCo Reference< XIndexAccess > xIndexAccess; for ( sal_Int32 j = 0; j < aPropSeq.getLength(); j++ ) { - if ( aPropSeq[j].Name.equalsAscii( "ItemDescriptorContainer" )) + if ( aPropSeq[j].Name.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "ItemDescriptorContainer" ) )) { aPropSeq[j].Value >>= xIndexAccess; nContainerIndex = j; @@ -182,7 +182,7 @@ void RootItemContainer::copyItemContainer( const std::vector< Sequence< Property Reference< XIndexAccess > xIndexAccess; for ( sal_Int32 j = 0; j < aPropSeq.getLength(); j++ ) { - if ( aPropSeq[j].Name.equalsAscii( "ItemDescriptorContainer" )) + if ( aPropSeq[j].Name.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "ItemDescriptorContainer" ) )) { aPropSeq[j].Value >>= xIndexAccess; nContainerIndex = j; diff --git a/framework/source/uielement/toolbarsmenucontroller.cxx b/framework/source/uielement/toolbarsmenucontroller.cxx index 8aeec65efd..fcf575b8ee 100644 --- a/framework/source/uielement/toolbarsmenucontroller.cxx +++ b/framework/source/uielement/toolbarsmenucontroller.cxx @@ -270,7 +270,7 @@ rtl::OUString ToolbarsMenuController::getUINameFromCommand( const rtl::OUString& { for ( sal_Int32 i = 0; i < aPropSeq.getLength(); i++ ) { - if ( aPropSeq[i].Name.equalsAscii( "Label" )) + if ( aPropSeq[i].Name.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "Label" ) )) { aPropSeq[i].Value >>= aStr; break; @@ -499,18 +499,18 @@ void ToolbarsMenuController::fillPopupMenu( Reference< css::awt::XPopupMenu >& r } // Create commands for non-toolbars - if ( m_aModuleIdentifier.equalsAscii( "com.sun.star.text.TextDocument" ) || - m_aModuleIdentifier.equalsAscii( "com.sun.star.text.WebDocument" ) || - m_aModuleIdentifier.equalsAscii( "com.sun.star.text.GlobalDocument" ) || - m_aModuleIdentifier.equalsAscii( "com.sun.star.drawing.DrawingDocument" ) || - m_aModuleIdentifier.equalsAscii( "com.sun.star.presentation.PresentationDocument" ) || - m_aModuleIdentifier.equalsAscii( "com.sun.star.sheet.SpreadsheetDocument" )) + if ( m_aModuleIdentifier.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "com.sun.star.text.TextDocument" ) ) || + m_aModuleIdentifier.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "com.sun.star.text.WebDocument" ) ) || + m_aModuleIdentifier.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "com.sun.star.text.GlobalDocument" ) ) || + m_aModuleIdentifier.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "com.sun.star.drawing.DrawingDocument" ) ) || + m_aModuleIdentifier.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "com.sun.star.presentation.PresentationDocument" ) ) || + m_aModuleIdentifier.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "com.sun.star.sheet.SpreadsheetDocument" ) )) { addCommand( m_xPopupMenu, rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( CMD_HYPERLINKBAR )), 10360, aEmptyString ); - if ( m_aModuleIdentifier.equalsAscii( "com.sun.star.drawing.DrawingDocument" ) || - m_aModuleIdentifier.equalsAscii( "com.sun.star.presentation.PresentationDocument" )) + if ( m_aModuleIdentifier.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "com.sun.star.drawing.DrawingDocument" ) ) || + m_aModuleIdentifier.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "com.sun.star.presentation.PresentationDocument" ) )) addCommand( m_xPopupMenu, rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( CMD_COLORBAR )), 10417, aEmptyString ); - else if ( m_aModuleIdentifier.equalsAscii( "com.sun.star.sheet.SpreadsheetDocument" )) + else if ( m_aModuleIdentifier.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "com.sun.star.sheet.SpreadsheetDocument" ) )) addCommand( m_xPopupMenu, rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( CMD_INPUTLINEBAR )), 26241, aEmptyString ); else addCommand( m_xPopupMenu, rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( CMD_FORMULABAR )), 20128, aEmptyString ); diff --git a/framework/source/uifactory/addonstoolboxfactory.cxx b/framework/source/uifactory/addonstoolboxfactory.cxx index f4383f4452..713449c602 100644 --- a/framework/source/uifactory/addonstoolboxfactory.cxx +++ b/framework/source/uifactory/addonstoolboxfactory.cxx @@ -177,11 +177,11 @@ throw ( ::com::sun::star::container::NoSuchElementException, for ( sal_Int32 n = 0; n < Args.getLength(); n++ ) { - if ( Args[n].Name.equalsAscii( "ConfigurationData" )) + if ( Args[n].Name.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "ConfigurationData" ) )) Args[n].Value >>= aConfigData; - else if ( Args[n].Name.equalsAscii( "Frame" )) + else if ( Args[n].Name.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "Frame" ) )) Args[n].Value >>= xFrame; - else if ( Args[n].Name.equalsAscii( "ResourceURL" )) + else if ( Args[n].Name.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "ResourceURL" ) )) Args[n].Value >>= aResourceURL; } diff --git a/framework/source/uifactory/windowcontentfactorymanager.cxx b/framework/source/uifactory/windowcontentfactorymanager.cxx index 22c68998a5..cea43a2a65 100644 --- a/framework/source/uifactory/windowcontentfactorymanager.cxx +++ b/framework/source/uifactory/windowcontentfactorymanager.cxx @@ -178,9 +178,9 @@ throw (uno::Exception, uno::RuntimeException) beans::PropertyValue aPropValue; if ( Arguments[i] >>= aPropValue ) { - if ( aPropValue.Name.equalsAscii( "Frame" )) + if ( aPropValue.Name.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "Frame" ) )) aPropValue.Value >>= xFrame; - else if ( aPropValue.Name.equalsAscii( "ResourceURL" )) + else if ( aPropValue.Name.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "ResourceURL" ) )) aPropValue.Value >>= aResourceURL; } } |