chart2/source/view/main/ChartView.cxx              |    2 +-
 cui/source/customize/cfg.cxx                       |    2 +-
 framework/inc/macros/registration.hxx              |    2 +-
 vcl/source/filter/FilterConfigCache.cxx            |    6 +++---
 xmloff/source/chart/SchXMLExport.cxx               |    2 +-
 xmloff/source/draw/shapeexport.cxx                 |    6 +++---
 xmlsecurity/source/xmlsec/mscrypt/xsec_mscrypt.cxx |   10 +++++-----
 xmlsecurity/source/xmlsec/nss/xsec_nss.cxx         |   12 ++++++------
 xmlsecurity/source/xmlsec/xsec_xmlsec.cxx          |    6 +++---
 9 files changed, 24 insertions(+), 24 deletions(-)

New commits:
commit cba5a9223a7e8141dc171c3e2e992ce1c0df8330
Author: Noel Grandin <[email protected]>
Date:   Tue Jul 12 21:16:26 2016 +0200

    no need to create temporary OUString for comparison
    
    Change-Id: I0a321e8ffbe379588a288084ec2e74e1a8c296b2
    Reviewed-on: https://gerrit.libreoffice.org/27171
    Tested-by: Jenkins <[email protected]>
    Reviewed-by: Noel Grandin <[email protected]>

diff --git a/chart2/source/view/main/ChartView.cxx 
b/chart2/source/view/main/ChartView.cxx
index 56c7a59..214cf3c 100644
--- a/chart2/source/view/main/ChartView.cxx
+++ b/chart2/source/view/main/ChartView.cxx
@@ -1485,7 +1485,7 @@ void lcl_setDefaultWritingMode( const std::shared_ptr< 
DrawModelWrapper >& pDraw
                                             uno::Reference< 
beans::XPropertySet > xEmbeddedProps( xEmbeddedObjects->getByName( aNames[nN] 
), uno::UNO_QUERY );
                                             if( xEmbeddedProps.is() )
                                             {
-                                                static OUString aChartCLSID = 
OUString( SvGlobalName( SO3_SCH_CLASSID ).GetHexName());
+                                                static OUString aChartCLSID = 
SvGlobalName( SO3_SCH_CLASSID ).GetHexName();
                                                 OUString aCLSID;
                                                 
xEmbeddedProps->getPropertyValue( "CLSID" ) >>= aCLSID;
                                                 if( aCLSID.equals(aChartCLSID) 
)
diff --git a/cui/source/customize/cfg.cxx b/cui/source/customize/cfg.cxx
index 088f4c5..24bcca6 100644
--- a/cui/source/customize/cfg.cxx
+++ b/cui/source/customize/cfg.cxx
@@ -4435,7 +4435,7 @@ void ToolbarSaveInData::LoadToolbar(
 
                 // If custom label not set retrieve it from the command
                 // to info service
-                if ( aLabel.equals( OUString() ) )
+                if ( aLabel.isEmpty() )
                 {
                     uno::Sequence< beans::PropertyValue > aPropSeq;
                     if ( a >>= aPropSeq )
diff --git a/framework/inc/macros/registration.hxx 
b/framework/inc/macros/registration.hxx
index 927b437..0e072e2 100644
--- a/framework/inc/macros/registration.hxx
+++ b/framework/inc/macros/registration.hxx
@@ -41,7 +41,7 @@ 
________________________________________________________________________________
 #define IFFACTORY( CLASS )                                                     
                                                         \
     /* If searched name found ... */                                           
                                                         \
     /* You can't add some statements before follow line ... Here can be an 
ELSE-statement! */                                           \
-    if ( CLASS::impl_getStaticImplementationName().equals( 
OUString::createFromAscii( pImplementationName ) ) )                  \
+    if ( CLASS::impl_getStaticImplementationName().equalsAscii( 
pImplementationName ) )                  \
     {                                                                          
                                                         \
         /* ... then create right factory for this service.                     
             */                                          \
         /* xFactory and xServiceManager are local variables of method which 
use this macro. */                                          \
diff --git a/vcl/source/filter/FilterConfigCache.cxx 
b/vcl/source/filter/FilterConfigCache.cxx
index 262bd66..33f0aa9 100644
--- a/vcl/source/filter/FilterConfigCache.cxx
+++ b/vcl/source/filter/FilterConfigCache.cxx
@@ -69,7 +69,7 @@ void 
FilterConfigCache::FilterConfigCacheEntry::CreateFilterName( const OUString
     const char** pPtr;
     for ( pPtr = InternalPixelFilterNameList; *pPtr && !bIsInternalFilter; 
pPtr++ )
     {
-        if ( sFilterName.equalsIgnoreAsciiCase( OUString(*pPtr, strlen(*pPtr), 
RTL_TEXTENCODING_ASCII_US) ) )
+        if ( sFilterName.equalsIgnoreAsciiCaseAscii( *pPtr ) )
         {
             bIsInternalFilter = true;
             bIsPixelFormat = true;
@@ -77,14 +77,14 @@ void 
FilterConfigCache::FilterConfigCacheEntry::CreateFilterName( const OUString
     }
     for ( pPtr = InternalVectorFilterNameList; *pPtr && !bIsInternalFilter; 
pPtr++ )
     {
-        if ( sFilterName.equalsIgnoreAsciiCase( OUString(*pPtr, strlen(*pPtr), 
RTL_TEXTENCODING_ASCII_US) ) )
+        if ( sFilterName.equalsIgnoreAsciiCaseAscii( *pPtr ) )
             bIsInternalFilter = true;
     }
     if ( !bIsInternalFilter )
     {
         for ( pPtr = ExternalPixelFilterNameList; *pPtr && !bIsPixelFormat; 
pPtr++ )
         {
-            if ( sFilterName.equalsIgnoreAsciiCase( OUString(*pPtr, 
strlen(*pPtr), RTL_TEXTENCODING_ASCII_US) ) )
+            if ( sFilterName.equalsIgnoreAsciiCaseAscii( *pPtr ) )
                 bIsPixelFormat = true;
         }
         sExternalFilterName = sFilterName;
diff --git a/xmloff/source/chart/SchXMLExport.cxx 
b/xmloff/source/chart/SchXMLExport.cxx
index 652e59c..5548b67 100644
--- a/xmloff/source/chart/SchXMLExport.cxx
+++ b/xmloff/source/chart/SchXMLExport.cxx
@@ -1031,7 +1031,7 @@ SchXMLExportHelper_Impl::SchXMLExportHelper_Impl(
         mbHasSeriesLabels( false ),
         mbHasCategoryLabels( false ),
         mbRowSourceColumns( true ),
-        msCLSID( OUString( SvGlobalName( SO3_SCH_CLASSID ).GetHexName()))
+        msCLSID( SvGlobalName( SO3_SCH_CLASSID ).GetHexName() )
 {
     msTableName = "local-table";
 
diff --git a/xmloff/source/draw/shapeexport.cxx 
b/xmloff/source/draw/shapeexport.cxx
index a6d4610..504c4b9 100644
--- a/xmloff/source/draw/shapeexport.cxx
+++ b/xmloff/source/draw/shapeexport.cxx
@@ -1115,11 +1115,11 @@ void XMLShapeExport::ImpCalcShapeType(const 
uno::Reference< drawing::XShape >& x
                         if(xPropSet->getPropertyValue("CLSID") >>= sCLSID)
                         {
                             if 
(sCLSID.equals(mrExport.GetChartExport()->getChartCLSID()) ||
-                                sCLSID.equals(OUString( SvGlobalName( 
SO3_RPTCH_CLASSID ).GetHexName())))
+                                sCLSID.equals( SvGlobalName( SO3_RPTCH_CLASSID 
).GetHexName() ))
                             {
                                 eShapeType = XmlShapeTypeDrawChartShape;
                             }
-                            else if (sCLSID.equals(OUString( SvGlobalName( 
SO3_SC_CLASSID ).GetHexName())))
+                            else if (sCLSID.equals( SvGlobalName( 
SO3_SC_CLASSID ).GetHexName() ))
                             {
                                 eShapeType = XmlShapeTypeDrawSheetShape;
                             }
@@ -1165,7 +1165,7 @@ void XMLShapeExport::ImpCalcShapeType(const 
uno::Reference< drawing::XShape >& x
                         OUString sCLSID;
                         if(xPropSet->getPropertyValue("CLSID") >>= sCLSID)
                         {
-                            if( sCLSID.equals(OUString( SvGlobalName( 
SO3_SC_CLASSID ).GetHexName())) )
+                            if( sCLSID.equals( SvGlobalName( SO3_SC_CLASSID 
).GetHexName() ) )
                             {
                                 eShapeType = XmlShapeTypePresSheetShape;
                             }
diff --git a/xmlsecurity/source/xmlsec/mscrypt/xsec_mscrypt.cxx 
b/xmlsecurity/source/xmlsec/mscrypt/xsec_mscrypt.cxx
index ece35be..47dac94 100644
--- a/xmlsecurity/source/xmlsec/mscrypt/xsec_mscrypt.cxx
+++ b/xmlsecurity/source/xmlsec/mscrypt/xsec_mscrypt.cxx
@@ -45,15 +45,15 @@ void* SAL_CALL mscrypt_component_getFactory( const 
sal_Char* pImplName , void* p
     Reference< XSingleServiceFactory > xFactory ;
 
     if( pImplName != NULL && pServiceManager != NULL ) {
-        if( XMLSignature_MSCryptImpl::impl_getImplementationName().equals( 
OUString::createFromAscii( pImplName ) ) ) {
+        if( 
XMLSignature_MSCryptImpl::impl_getImplementationName().equalsAscii( pImplName ) 
) {
             xFactory = XMLSignature_MSCryptImpl::impl_createFactory( 
reinterpret_cast< XMultiServiceFactory* >( pServiceManager ) ) ;
-        } else if( 
XMLSecurityContext_MSCryptImpl::impl_getImplementationName().equals( 
OUString::createFromAscii( pImplName ) ) ) {
+        } else if( 
XMLSecurityContext_MSCryptImpl::impl_getImplementationName().equalsAscii( 
pImplName ) ) {
             xFactory = XMLSecurityContext_MSCryptImpl::impl_createFactory( 
reinterpret_cast< XMultiServiceFactory* >( pServiceManager ) ) ;
-        } else if( 
SecurityEnvironment_MSCryptImpl::impl_getImplementationName().equals( 
OUString::createFromAscii( pImplName ) ) ) {
+        } else if( 
SecurityEnvironment_MSCryptImpl::impl_getImplementationName().equalsAscii( 
pImplName ) ) {
             xFactory = SecurityEnvironment_MSCryptImpl::impl_createFactory( 
reinterpret_cast< XMultiServiceFactory* >( pServiceManager ) ) ;
-        } else if( 
XMLEncryption_MSCryptImpl::impl_getImplementationName().equals( 
OUString::createFromAscii( pImplName ) ) ) {
+        } else if( 
XMLEncryption_MSCryptImpl::impl_getImplementationName().equalsAscii( pImplName 
) ) {
             xFactory = XMLEncryption_MSCryptImpl::impl_createFactory( 
reinterpret_cast< XMultiServiceFactory* >( pServiceManager ) ) ;
-        } else if( SEInitializer_MSCryptImpl_getImplementationName().equals( 
OUString::createFromAscii( pImplName ) ) ) {
+        } else if( 
SEInitializer_MSCryptImpl_getImplementationName().equalsAscii( pImplName ) ) {
             xFactory.set( createSingleFactory(
                 reinterpret_cast< XMultiServiceFactory * >( pServiceManager ),
                 OUString::createFromAscii( pImplName ),
diff --git a/xmlsecurity/source/xmlsec/nss/xsec_nss.cxx 
b/xmlsecurity/source/xmlsec/nss/xsec_nss.cxx
index 3a46eaa..33ab82c 100644
--- a/xmlsecurity/source/xmlsec/nss/xsec_nss.cxx
+++ b/xmlsecurity/source/xmlsec/nss/xsec_nss.cxx
@@ -48,31 +48,31 @@ void* SAL_CALL nss_component_getFactory( const sal_Char* 
pImplName , void* pServ
     if( pImplName != nullptr && pServiceManager != nullptr )
     {
 #ifdef XMLSEC_CRYPTO_NSS
-        if( SEInitializer_NssImpl_getImplementationName().equals( 
OUString::createFromAscii( pImplName ) ) )
+        if( SEInitializer_NssImpl_getImplementationName().equalsAscii( 
pImplName ) )
         {
             xFactory.set( createSingleFactory(
                 static_cast< XMultiServiceFactory * >( pServiceManager ),
                 OUString::createFromAscii( pImplName ),
                 SEInitializer_NssImpl_createInstance, 
SEInitializer_NssImpl_getSupportedServiceNames() ) );
         }
-        else if( XMLSignature_NssImpl::impl_getImplementationName().equals( 
OUString::createFromAscii( pImplName ) ) )
+        else if( 
XMLSignature_NssImpl::impl_getImplementationName().equalsAscii( pImplName ) )
         {
             xFactory = XMLSignature_NssImpl::impl_createFactory( static_cast< 
XMultiServiceFactory* >( pServiceManager ) ) ;
         }
-        else if( 
XMLSecurityContext_NssImpl::impl_getImplementationName().equals( 
OUString::createFromAscii( pImplName ) ) )
+        else if( 
XMLSecurityContext_NssImpl::impl_getImplementationName().equalsAscii( pImplName 
) )
         {
             xFactory = XMLSecurityContext_NssImpl::impl_createFactory( 
static_cast< XMultiServiceFactory* >( pServiceManager ) ) ;
         }
-        else if( 
SecurityEnvironment_NssImpl::impl_getImplementationName().equals( 
OUString::createFromAscii( pImplName ) ) )
+        else if( 
SecurityEnvironment_NssImpl::impl_getImplementationName().equalsAscii( 
pImplName ) )
         {
             xFactory = SecurityEnvironment_NssImpl::impl_createFactory( 
static_cast< XMultiServiceFactory* >( pServiceManager ) ) ;
         }
-        else if( XMLEncryption_NssImpl::impl_getImplementationName().equals( 
OUString::createFromAscii( pImplName ) ) )
+        else if( 
XMLEncryption_NssImpl::impl_getImplementationName().equalsAscii( pImplName ) )
         {
             xFactory = XMLEncryption_NssImpl::impl_createFactory( static_cast< 
XMultiServiceFactory* >( pServiceManager ) ) ;
         }
 #else
-        if( ONSSInitializer_getImplementationName().equals( 
OUString::createFromAscii( pImplName ) ) )
+        if( ONSSInitializer_getImplementationName().equalsAscii( pImplName ) )
         {
             xFactory.set( createSingleFactory(
                 reinterpret_cast< XMultiServiceFactory * >( pServiceManager ),
diff --git a/xmlsecurity/source/xmlsec/xsec_xmlsec.cxx 
b/xmlsecurity/source/xmlsec/xsec_xmlsec.cxx
index 8f0777c..3b973e1 100644
--- a/xmlsecurity/source/xmlsec/xsec_xmlsec.cxx
+++ b/xmlsecurity/source/xmlsec/xsec_xmlsec.cxx
@@ -40,21 +40,21 @@ SAL_DLLPUBLIC_EXPORT void* SAL_CALL 
xsec_xmlsec_component_getFactory( const sal_
     Reference< XInterface > xFactory ;
 
     if( pImplName != nullptr ) {
-        if( XMLElementWrapper_XmlSecImpl_getImplementationName().equals( 
OUString::createFromAscii( pImplName ) ) )
+        if( XMLElementWrapper_XmlSecImpl_getImplementationName().equalsAscii( 
pImplName ) )
         {
             xFactory = cppu::createSingleComponentFactory(
                 XMLElementWrapper_XmlSecImpl_createInstance,
                 OUString::createFromAscii( pImplName ),
                 XMLElementWrapper_XmlSecImpl_getSupportedServiceNames() );
         }
-        else if( XMLDocumentWrapper_XmlSecImpl_getImplementationName().equals( 
OUString::createFromAscii( pImplName ) ) )
+        else if( 
XMLDocumentWrapper_XmlSecImpl_getImplementationName().equalsAscii( pImplName ) )
         {
             xFactory = cppu::createSingleComponentFactory(
                 XMLDocumentWrapper_XmlSecImpl_createInstance,
                 OUString::createFromAscii( pImplName ),
                 XMLDocumentWrapper_XmlSecImpl_getSupportedServiceNames() );
         }
-        else if( 
xml_security::serial_number_adapter::implementationName().equals( 
OUString::createFromAscii( pImplName ) ) )
+        else if( 
xml_security::serial_number_adapter::implementationName().equalsAscii( 
pImplName ) )
         {
             xFactory = ::cppu::createSingleComponentFactory(
               xml_security::serial_number_adapter::create,
_______________________________________________
Libreoffice-commits mailing list
[email protected]
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits

Reply via email to