diff options
author | Caolán McNamara <caolanm@redhat.com> | 2011-01-17 11:11:14 +0000 |
---|---|---|
committer | Caolán McNamara <caolanm@redhat.com> | 2011-01-17 11:11:14 +0000 |
commit | 410bc1e5a466531cfe052f7c25f50f97262d80c1 (patch) | |
tree | 56026bec5708f9a227550deb47f044b952b4b19d | |
parent | 40c202b083b865ac733b9456cd018e48bb508031 (diff) |
equalsAsciiL faster than equalsAscii
4 files changed, 8 insertions, 8 deletions
diff --git a/framework/source/uiconfiguration/moduleuicfgsupplier.cxx b/framework/source/uiconfiguration/moduleuicfgsupplier.cxx index db799fd39a..1043a26510 100644 --- a/framework/source/uiconfiguration/moduleuicfgsupplier.cxx +++ b/framework/source/uiconfiguration/moduleuicfgsupplier.cxx @@ -211,7 +211,7 @@ throw ( NoSuchElementException, RuntimeException) xCont->getByName(ModuleIdentifier) >>= lProps; for (sal_Int32 i=0; i<lProps.getLength(); ++i) { - if (lProps[i].Name.equalsAscii("ooSetupFactoryShortName")) + if (lProps[i].Name.equalsAsciiL(RTL_CONSTASCII_STRINGPARAM("ooSetupFactoryShortName"))) { lProps[i].Value >>= sShort; break; diff --git a/framework/source/uiconfiguration/windowstateconfiguration.cxx b/framework/source/uiconfiguration/windowstateconfiguration.cxx index b2429d5619..e4f2de761c 100644 --- a/framework/source/uiconfiguration/windowstateconfiguration.cxx +++ b/framework/source/uiconfiguration/windowstateconfiguration.cxx @@ -1393,7 +1393,7 @@ WindowStateConfiguration::WindowStateConfiguration( const Reference< XMultiServi ::rtl::OUString aWindowStateFileStr; for ( sal_Int32 y = 0; y < aSeq.getLength(); y++ ) { - if ( aSeq[y].Name.equalsAscii("ooSetupFactoryWindowStateConfigRef") ) + if ( aSeq[y].Name.equalsAsciiL(RTL_CONSTASCII_STRINGPARAM("ooSetupFactoryWindowStateConfigRef")) ) { aSeq[y].Value >>= aWindowStateFileStr; break; diff --git a/framework/source/uifactory/menubarfactory.cxx b/framework/source/uifactory/menubarfactory.cxx index ce062788de..4ae733e4e1 100644 --- a/framework/source/uifactory/menubarfactory.cxx +++ b/framework/source/uifactory/menubarfactory.cxx @@ -133,17 +133,17 @@ void MenuBarFactory::CreateUIElement(const ::rtl::OUString& ResourceURL for ( sal_Int32 n = 0; n < Args.getLength(); n++ ) { - if ( Args[n].Name.equalsAscii( "ConfigurationSource" )) + if ( Args[n].Name.equalsAsciiL(RTL_CONSTASCII_STRINGPARAM("ConfigurationSource")) ) Args[n].Value >>= xConfigSource; - 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; - else if ( Args[n].Name.equalsAscii( "Persistent" )) + else if ( Args[n].Name.equalsAsciiL(RTL_CONSTASCII_STRINGPARAM("Persistent")) ) Args[n].Value >>= bPersistent; else if ( _pExtraMode && Args[n].Name.equalsAscii( _pExtraMode )) Args[n].Value >>= bExtraMode; - } // for ( sal_Int32 n = 0; n < Args.getLength(); n++ ) + } if ( aResourceURL.indexOf( rtl::OUString::createFromAscii(_pAsciiName)) != 0 ) throw IllegalArgumentException(); diff --git a/ucb/source/ucp/file/filglob.cxx b/ucb/source/ucp/file/filglob.cxx index c5dcd4cbf2..3b7af59ede 100644 --- a/ucb/source/ucp/file/filglob.cxx +++ b/ucb/source/ucp/file/filglob.cxx @@ -224,7 +224,7 @@ namespace fileaccess { if( aParent[ aParent.getLength()-1] == sal_Unicode(':') && aParent.getLength() == 6 ) aParent += rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("/")); - if( 0 == aParent.compareToAscii( "file://" ) ) + if( aParent.equalsAsciiL(RTL_CONSTASCII_STRINGPARAM("file://")) ) aParent = rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("file:///")); return aParent; |