From 88fa511a7748ff920546bd28ac9e15f5e0ba2fb0 Mon Sep 17 00:00:00 2001 From: Thomas Arnhold Date: Thu, 20 Jan 2011 11:23:45 +0100 Subject: Replace suitable equalsAscii calls with equalsAsciiL. Done with sed -i 's%\(\.equalsAscii\)(\(\s\?"[^"]\+"\)\(\s\?\))%\1L(\3RTL_CONSTASCII_STRINGPARAM(\2\3)\3)%g'. --- embeddedobj/source/msole/olecomponent.cxx | 2 +- embeddedobj/source/msole/oleembed.cxx | 2 +- embeddedobj/source/msole/olepersist.cxx | 12 ++++++------ embeddedobj/source/msole/ownview.cxx | 6 +++--- embeddedobj/source/msole/xolefactory.cxx | 2 +- 5 files changed, 12 insertions(+), 12 deletions(-) (limited to 'embeddedobj/source/msole') diff --git a/embeddedobj/source/msole/olecomponent.cxx b/embeddedobj/source/msole/olecomponent.cxx index 616e3fc17d36..2b45ba7aefd4 100644 --- a/embeddedobj/source/msole/olecomponent.cxx +++ b/embeddedobj/source/msole/olecomponent.cxx @@ -1599,7 +1599,7 @@ uno::Any SAL_CALL OleComponent::getTransferData( const datatransfer::DataFlavor& // TODO: Investigate if there is already the format name // and whether this format is really required else if ( aFlavor.DataType == getCppuType( ( const uno::Reference< io::XInputStream >* ) 0 ) - && aFlavor.MimeType.equalsAscii( "application/x-openoffice-contentstream" ) ) + && aFlavor.MimeType.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "application/x-openoffice-contentstream" ) ) ) { // allow to retrieve stream-representation of the object persistence bSupportedFlavor = sal_True; diff --git a/embeddedobj/source/msole/oleembed.cxx b/embeddedobj/source/msole/oleembed.cxx index c441693f4917..5c0f9376578f 100644 --- a/embeddedobj/source/msole/oleembed.cxx +++ b/embeddedobj/source/msole/oleembed.cxx @@ -296,7 +296,7 @@ sal_Bool OleEmbeddedObject::TryToConvertToOOo() if ( aFilterAnyData >>= aFilterData ) { for ( sal_Int32 nInd = 0; nInd < aFilterData.getLength(); nInd++ ) - if ( aFilterData[nInd].Name.equalsAscii( "DocumentService" ) ) + if ( aFilterData[nInd].Name.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "DocumentService" ) ) ) aFilterData[nInd].Value >>= aDocServiceName; } diff --git a/embeddedobj/source/msole/olepersist.cxx b/embeddedobj/source/msole/olepersist.cxx index 14e670acd06e..72266e50b729 100644 --- a/embeddedobj/source/msole/olepersist.cxx +++ b/embeddedobj/source/msole/olepersist.cxx @@ -1149,11 +1149,11 @@ void OleEmbeddedObject::StoreToLocation_Impl( uno::Reference< io::XStream > xCachedVisualRepresentation; for ( sal_Int32 nInd = 0; nInd < lObjArgs.getLength(); nInd++ ) { - if ( lObjArgs[nInd].Name.equalsAscii( "StoreVisualReplacement" ) ) + if ( lObjArgs[nInd].Name.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "StoreVisualReplacement" ) ) ) lObjArgs[nInd].Value >>= bStoreVis; - else if ( lObjArgs[nInd].Name.equalsAscii( "VisualReplacement" ) ) + else if ( lObjArgs[nInd].Name.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "VisualReplacement" ) ) ) lObjArgs[nInd].Value >>= xCachedVisualRepresentation; - else if ( lObjArgs[nInd].Name.equalsAscii( "CanTryOptimization" ) ) + else if ( lObjArgs[nInd].Name.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "CanTryOptimization" ) ) ) lObjArgs[nInd].Value >>= bTryOptimization; } @@ -1410,7 +1410,7 @@ void SAL_CALL OleEmbeddedObject::setPersistentEntry( m_bReadOnly = sal_False; sal_Int32 nInd = 0; for ( nInd = 0; nInd < lArguments.getLength(); nInd++ ) - if ( lArguments[nInd].Name.equalsAscii( "ReadOnly" ) ) + if ( lArguments[nInd].Name.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "ReadOnly" ) ) ) lArguments[nInd].Value >>= m_bReadOnly; #ifdef WNT @@ -1420,7 +1420,7 @@ void SAL_CALL OleEmbeddedObject::setPersistentEntry( SwitchOwnPersistence( xStorage, sEntName ); for ( nInd = 0; nInd < lObjArgs.getLength(); nInd++ ) - if ( lObjArgs[nInd].Name.equalsAscii( "StoreVisualReplacement" ) ) + if ( lObjArgs[nInd].Name.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "StoreVisualReplacement" ) ) ) lObjArgs[nInd].Value >>= m_bStoreVisRepl; #ifdef WNT @@ -1488,7 +1488,7 @@ void SAL_CALL OleEmbeddedObject::setPersistentEntry( // use URL ( may be content or stream later ) from MediaDescriptor to initialize object ::rtl::OUString aURL; for ( sal_Int32 nInd = 0; nInd < lArguments.getLength(); nInd++ ) - if ( lArguments[nInd].Name.equalsAscii( "URL" ) ) + if ( lArguments[nInd].Name.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "URL" ) ) ) lArguments[nInd].Value >>= aURL; if ( !aURL.getLength() ) diff --git a/embeddedobj/source/msole/ownview.cxx b/embeddedobj/source/msole/ownview.cxx index 5e158fef6e91..16f3968bd5d3 100644 --- a/embeddedobj/source/msole/ownview.cxx +++ b/embeddedobj/source/msole/ownview.cxx @@ -241,7 +241,7 @@ sal_Bool OwnView_Impl::CreateModel( sal_Bool bUseNative ) ::rtl::OUString aFilterName; for ( sal_Int32 nInd = 0; nInd < aArgs.getLength(); nInd++ ) - if ( aArgs[nInd].Name.equalsAscii( "FilterName" ) ) + if ( aArgs[nInd].Name.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "FilterName" ) ) ) aArgs[nInd].Value >>= aFilterName; if ( !aFilterName.getLength() && aTypeName.getLength() ) @@ -254,7 +254,7 @@ sal_Bool OwnView_Impl::CreateModel( sal_Bool bUseNative ) { for ( sal_Int32 nInd = 0; nInd < aTypes.getLength(); nInd++ ) { - if ( aTypes[nInd].Name.equalsAscii( "PreferredFilter" ) && ( aTypes[nInd].Value >>= aFilterName ) ) + if ( aTypes[nInd].Name.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "PreferredFilter" ) ) && ( aTypes[nInd].Value >>= aFilterName ) ) { aTypes[nInd].Value >>= aFilterName; break; @@ -609,7 +609,7 @@ void SAL_CALL OwnView_Impl::notifyEvent( const document::EventObject& aEvent ) { ::osl::MutexGuard aGuard( m_aMutex ); - if ( aEvent.Source == m_xModel && aEvent.EventName.equalsAscii( "OnSaveAsDone" ) ) + if ( aEvent.Source == m_xModel && aEvent.EventName.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "OnSaveAsDone" ) ) ) { // SaveAs operation took place, so just forget the model and deregister listeners xModel = m_xModel; diff --git a/embeddedobj/source/msole/xolefactory.cxx b/embeddedobj/source/msole/xolefactory.cxx index 0b1ea1e2542b..9529541cd02c 100644 --- a/embeddedobj/source/msole/xolefactory.cxx +++ b/embeddedobj/source/msole/xolefactory.cxx @@ -123,7 +123,7 @@ uno::Reference< uno::XInterface > SAL_CALL OleEmbeddedObjectFactory::createInsta for ( sal_Int32 nInd = 0; nInd < lObjArgs.getLength(); nInd++ ) { - if ( lObjArgs[nInd].Name.equalsAscii( "CloneFrom" ) ) + if ( lObjArgs[nInd].Name.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "CloneFrom" ) ) ) { try { -- cgit