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 /sfx2 | |
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 'sfx2')
-rw-r--r-- | sfx2/inc/sfx2/XmlIdRegistry.hxx | 4 | ||||
-rw-r--r-- | sfx2/source/appl/appserv.cxx | 2 | ||||
-rw-r--r-- | sfx2/source/control/unoctitm.cxx | 4 | ||||
-rw-r--r-- | sfx2/source/dialog/dockwin.cxx | 2 | ||||
-rw-r--r-- | sfx2/source/dialog/filedlghelper.cxx | 2 | ||||
-rw-r--r-- | sfx2/source/dialog/recfloat.cxx | 2 | ||||
-rw-r--r-- | sfx2/source/dialog/templdlg.cxx | 2 | ||||
-rw-r--r-- | sfx2/source/doc/DocumentMetadataAccess.cxx | 4 | ||||
-rw-r--r-- | sfx2/source/doc/SfxDocumentMetaData.cxx | 16 | ||||
-rw-r--r-- | sfx2/source/doc/docfac.cxx | 2 | ||||
-rw-r--r-- | sfx2/source/doc/doctemplates.cxx | 2 | ||||
-rw-r--r-- | sfx2/source/doc/graphhelp.cxx | 10 | ||||
-rw-r--r-- | sfx2/source/doc/guisaveas.cxx | 16 | ||||
-rw-r--r-- | sfx2/source/doc/objstor.cxx | 6 | ||||
-rw-r--r-- | sfx2/source/doc/plugin.cxx | 12 | ||||
-rw-r--r-- | sfx2/source/doc/sfxmodelfactory.cxx | 6 | ||||
-rw-r--r-- | sfx2/source/toolbox/tbxitem.cxx | 2 | ||||
-rw-r--r-- | sfx2/source/view/ipclient.cxx | 2 | ||||
-rw-r--r-- | sfx2/source/view/viewfrm.cxx | 2 | ||||
-rw-r--r-- | sfx2/source/view/viewfrm2.cxx | 2 | ||||
-rw-r--r-- | sfx2/source/view/viewprn.cxx | 10 | ||||
-rw-r--r-- | sfx2/source/view/viewsh.cxx | 18 | ||||
-rw-r--r-- | sfx2/workben/custompanel/ctp_factory.cxx | 2 |
23 files changed, 65 insertions, 65 deletions
diff --git a/sfx2/inc/sfx2/XmlIdRegistry.hxx b/sfx2/inc/sfx2/XmlIdRegistry.hxx index b71b1f46af..38090e3546 100644 --- a/sfx2/inc/sfx2/XmlIdRegistry.hxx +++ b/sfx2/inc/sfx2/XmlIdRegistry.hxx @@ -52,8 +52,8 @@ isValidXmlId(::rtl::OUString const & i_rStreamName, ::rtl::OUString const & i_rIdref) { return isValidNCName(i_rIdref) && - (i_rStreamName.equalsAscii("content.xml") || - i_rStreamName.equalsAscii("styles.xml")); + (i_rStreamName.equalsAsciiL(RTL_CONSTASCII_STRINGPARAM("content.xml")) || + i_rStreamName.equalsAsciiL(RTL_CONSTASCII_STRINGPARAM("styles.xml"))); } diff --git a/sfx2/source/appl/appserv.cxx b/sfx2/source/appl/appserv.cxx index 68c45e3c27..55967a1f9d 100644 --- a/sfx2/source/appl/appserv.cxx +++ b/sfx2/source/appl/appserv.cxx @@ -909,7 +909,7 @@ namespace { Reference < XFrame > xFrame( xContainer->getByIndex(i), UNO_QUERY_THROW ); ::rtl::OUString sModule = xCheck->identify( xFrame ); - if ( sModule.equalsAscii( "com.sun.star.frame.StartModule" ) ) + if ( sModule.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "com.sun.star.frame.StartModule" ) ) ) return xFrame; } catch( const UnknownModuleException& ) diff --git a/sfx2/source/control/unoctitm.cxx b/sfx2/source/control/unoctitm.cxx index 8ca5f20dca..8c15a25788 100644 --- a/sfx2/source/control/unoctitm.cxx +++ b/sfx2/source/control/unoctitm.cxx @@ -449,7 +449,7 @@ sal_Bool SfxOfficeDispatch::IsMasterUnoCommand() const // Determine if URL contains a master/slave command which must be handled a little bit different sal_Bool SfxOfficeDispatch::IsMasterUnoCommand( const ::com::sun::star::util::URL& aURL ) { - if ( aURL.Protocol.equalsAscii( ".uno:" ) && + if ( aURL.Protocol.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( ".uno:" ) ) && ( aURL.Path.indexOf( '.' ) > 0 )) return sal_True; @@ -485,7 +485,7 @@ SfxDispatchController_Impl::SfxDispatchController_Impl( , bVisible( sal_True ) , pUnoName( pSlot->pUnoName ) { - if ( aDispatchURL.Protocol.equalsAscii("slot:") && pUnoName ) + if ( aDispatchURL.Protocol.equalsAsciiL(RTL_CONSTASCII_STRINGPARAM("slot:")) && pUnoName ) { ByteString aTmp(".uno:"); aTmp += pUnoName; diff --git a/sfx2/source/dialog/dockwin.cxx b/sfx2/source/dialog/dockwin.cxx index da195fe532..d370082a2d 100644 --- a/sfx2/source/dialog/dockwin.cxx +++ b/sfx2/source/dialog/dockwin.cxx @@ -117,7 +117,7 @@ static bool lcl_getWindowState( const uno::Reference< container::XNameAccess >& { for ( sal_Int32 n = 0; n < aWindowState.getLength(); n++ ) { - if ( aWindowState[n].Name.equalsAscii( "UIName" )) + if ( aWindowState[n].Name.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "UIName" ) )) { aWindowState[n].Value >>= rWindowState.sTitle; } diff --git a/sfx2/source/dialog/filedlghelper.cxx b/sfx2/source/dialog/filedlghelper.cxx index 9ab7c21000..9b5bdfe9be 100644 --- a/sfx2/source/dialog/filedlghelper.cxx +++ b/sfx2/source/dialog/filedlghelper.cxx @@ -532,7 +532,7 @@ void FileDialogHelper_Impl::updateSelectionBox() Sequence< ::rtl::OUString > aCtrlList = xCtrlInfo->getSupportedControls(); sal_uInt32 nCount = aCtrlList.getLength(); for ( sal_uInt32 nCtrl = 0; nCtrl < nCount; ++nCtrl ) - if ( aCtrlList[ nCtrl ].equalsAscii("SelectionBox") ) + if ( aCtrlList[ nCtrl ].equalsAsciiL(RTL_CONSTASCII_STRINGPARAM("SelectionBox")) ) { bSelectionBoxFound = sal_False; break; diff --git a/sfx2/source/dialog/recfloat.cxx b/sfx2/source/dialog/recfloat.cxx index 6b53251891..b46cd564f9 100644 --- a/sfx2/source/dialog/recfloat.cxx +++ b/sfx2/source/dialog/recfloat.cxx @@ -129,7 +129,7 @@ static rtl::OUString GetLabelFromCommandURL( const rtl::OUString& rCommandURL, c { 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 >>= aLabel; break; diff --git a/sfx2/source/dialog/templdlg.cxx b/sfx2/source/dialog/templdlg.cxx index 3783eedce9..e210a7aeef 100644 --- a/sfx2/source/dialog/templdlg.cxx +++ b/sfx2/source/dialog/templdlg.cxx @@ -2546,7 +2546,7 @@ IMPL_LINK_INLINE_END( SfxTemplateDialog_Impl, ToolBoxLSelect, ToolBox *, pBox ) { 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 >>= sRet; break; diff --git a/sfx2/source/doc/DocumentMetadataAccess.cxx b/sfx2/source/doc/DocumentMetadataAccess.cxx index b477a327aa..aaa74e1c23 100644 --- a/sfx2/source/doc/DocumentMetadataAccess.cxx +++ b/sfx2/source/doc/DocumentMetadataAccess.cxx @@ -250,8 +250,8 @@ static bool isFileNameValid(const ::rtl::OUString & i_rFileName) const ::rtl::OUString segment( i_rFileName.getToken(0, static_cast<sal_Unicode> ('/'), idx) ); if (!segment.getLength() || // no empty segments - segment.equalsAscii(".") || // no . segments - segment.equalsAscii("..") || // no .. segments + segment.equalsAsciiL(RTL_CONSTASCII_STRINGPARAM(".")) || // no . segments + segment.equalsAsciiL(RTL_CONSTASCII_STRINGPARAM("..")) || // no .. segments !::comphelper::OStorageHelper::IsValidZipEntryFileName( segment, sal_False)) // no invalid characters return false; diff --git a/sfx2/source/doc/SfxDocumentMetaData.cxx b/sfx2/source/doc/SfxDocumentMetaData.cxx index 2379dd7a14..8881443278 100644 --- a/sfx2/source/doc/SfxDocumentMetaData.cxx +++ b/sfx2/source/doc/SfxDocumentMetaData.cxx @@ -543,9 +543,9 @@ getQualifier(const char* i_name) { DBG_ASSERT(i_qname, "SfxDocumentMetaData: getNameSpace: argument is null"); const char * ns = ""; ::rtl::OUString n = getQualifier(i_qname).first; - if (n.equalsAscii("xlink" )) ns = s_nsXLink; + if (n.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM("xlink" ) )) ns = s_nsXLink; if (n.equalsAscii("dc" )) ns = s_nsDC; - if (n.equalsAscii("office")) ns = s_nsODF; + if (n.equalsAsciiL(RTL_CONSTASCII_STRINGPARAM("office"))) ns = s_nsODF; if (n.equalsAscii("meta" )) ns = s_nsODFMeta; DBG_ASSERT(*ns, "SfxDocumentMetaData: unknown namespace prefix"); return ::rtl::OUString::createFromAscii(ns); @@ -1126,7 +1126,7 @@ void SAL_CALL SfxDocumentMetaData::updateUserDefinedAndAttributes() static_cast<const char*>("office:target-frame-name"), m_DefaultTarget)); // xlink:show: _blank -> new, any other value -> replace - const sal_Char* show = m_DefaultTarget.equalsAscii("_blank") + const sal_Char* show = m_DefaultTarget.equalsAsciiL(RTL_CONSTASCII_STRINGPARAM("_blank")) ? "new" : "replace"; attributes.push_back(std::make_pair( static_cast<const char*>("xlink:show"), @@ -1316,7 +1316,7 @@ void SAL_CALL SfxDocumentMetaData::init( ::rtl::OUString::createFromAscii(s_nsODFMeta), ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("value-type"))); ::rtl::OUString text = getNodeText(*it); - if (type.equalsAscii("float")) { + if (type.equalsAsciiL(RTL_CONSTASCII_STRINGPARAM("float"))) { double d; if (::sax::Converter::convertDouble(d, text)) { any <<= d; @@ -1325,7 +1325,7 @@ void SAL_CALL SfxDocumentMetaData::init( OUStringToOString(text, RTL_TEXTENCODING_UTF8).getStr()); continue; } - } else if (type.equalsAscii("date")) { + } else if (type.equalsAsciiL(RTL_CONSTASCII_STRINGPARAM("date"))) { bool isDateTime; css::util::Date d; css::util::DateTime dt; @@ -1340,7 +1340,7 @@ void SAL_CALL SfxDocumentMetaData::init( OUStringToOString(text, RTL_TEXTENCODING_UTF8).getStr()); continue; } - } else if (type.equalsAscii("time")) { + } else if (type.equalsAsciiL(RTL_CONSTASCII_STRINGPARAM("time"))) { css::util::Duration ud; if (textToDuration(ud, text)) { any <<= ud; @@ -1349,7 +1349,7 @@ void SAL_CALL SfxDocumentMetaData::init( OUStringToOString(text, RTL_TEXTENCODING_UTF8).getStr()); continue; } - } else if (type.equalsAscii("boolean")) { + } else if (type.equalsAsciiL(RTL_CONSTASCII_STRINGPARAM("boolean"))) { bool b; if (::sax::Converter::convertBool(b, text)) { any <<= b; @@ -1358,7 +1358,7 @@ void SAL_CALL SfxDocumentMetaData::init( OUStringToOString(text, RTL_TEXTENCODING_UTF8).getStr()); continue; } - } else if (type.equalsAscii("string") || true) { // default + } else if (type.equalsAsciiL(RTL_CONSTASCII_STRINGPARAM("string")) || true) { // default any <<= text; } try { diff --git a/sfx2/source/doc/docfac.cxx b/sfx2/source/doc/docfac.cxx index cd10edbe8e..b92975e68b 100644 --- a/sfx2/source/doc/docfac.cxx +++ b/sfx2/source/doc/docfac.cxx @@ -254,7 +254,7 @@ void SfxObjectFactory::SetSystemTemplate( const String& rServiceName, const Stri uno::Sequence< beans::PropertyValue > aActuralFilterData; xFilterFactory->getByName( aActualFilter ) >>= aActuralFilterData; for ( sal_Int32 nInd = 0; nInd < aActuralFilterData.getLength(); nInd++ ) - if ( aActuralFilterData[nInd].Name.equalsAscii( "Type" ) ) + if ( aActuralFilterData[nInd].Name.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "Type" ) ) ) aActuralFilterData[nInd].Value >>= aActualFilterTypeName; ::comphelper::SequenceAsHashMap aProps1( xTypeDetection->getByName( aActualFilterTypeName ) ); uno::Sequence< ::rtl::OUString > aAllExt = diff --git a/sfx2/source/doc/doctemplates.cxx b/sfx2/source/doc/doctemplates.cxx index 7851716200..9a82256652 100644 --- a/sfx2/source/doc/doctemplates.cxx +++ b/sfx2/source/doc/doctemplates.cxx @@ -1870,7 +1870,7 @@ sal_Bool SfxDocTplService_Impl::storeTemplate( const OUString& rGroupName, uno::Sequence< beans::PropertyValue > aFilterData; xFilterFactory->getByName( aFilterName ) >>= aFilterData; for ( sal_Int32 nInd = 0; nInd < aFilterData.getLength(); nInd++ ) - if ( aFilterData[nInd].Name.equalsAscii( "Type" ) ) + if ( aFilterData[nInd].Name.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "Type" ) ) ) aFilterData[nInd].Value >>= aTypeName; if ( !aTypeName.getLength() ) diff --git a/sfx2/source/doc/graphhelp.cxx b/sfx2/source/doc/graphhelp.cxx index 524c698583..d2589e1888 100644 --- a/sfx2/source/doc/graphhelp.cxx +++ b/sfx2/source/doc/graphhelp.cxx @@ -504,23 +504,23 @@ sal_uInt16 GraphicHelper::getThumbnailReplacementIDByFactoryName_Impl( const ::r { sal_uInt16 nResult = 0; - if ( aFactoryShortName.equalsAscii( "scalc" ) ) + if ( aFactoryShortName.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "scalc" ) ) ) { nResult = BMP_128X128_CALC_DOC; } - else if ( aFactoryShortName.equalsAscii( "sdraw" ) ) + else if ( aFactoryShortName.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "sdraw" ) ) ) { nResult = BMP_128X128_DRAW_DOC; } - else if ( aFactoryShortName.equalsAscii( "simpress" ) ) + else if ( aFactoryShortName.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "simpress" ) ) ) { nResult = BMP_128X128_IMPRESS_DOC; } - else if ( aFactoryShortName.equalsAscii( "smath" ) ) + else if ( aFactoryShortName.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "smath" ) ) ) { nResult = BMP_128X128_MATH_DOC; } - else if ( aFactoryShortName.equalsAscii( "swriter" ) || aFactoryShortName.compareToAscii( "swriter/", 8 ) == 0 ) + else if ( aFactoryShortName.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "swriter" ) ) || aFactoryShortName.compareToAscii( "swriter/", 8 ) == 0 ) { nResult = BMP_128X128_WRITER_DOC; } diff --git a/sfx2/source/doc/guisaveas.cxx b/sfx2/source/doc/guisaveas.cxx index a2a7e07cac..aa68646384 100644 --- a/sfx2/source/doc/guisaveas.cxx +++ b/sfx2/source/doc/guisaveas.cxx @@ -141,15 +141,15 @@ static sal_uInt16 getSlotIDFromMode( sal_Int8 nStoreMode ) static sal_uInt8 getStoreModeFromSlotName( const ::rtl::OUString& aSlotName ) { sal_uInt8 nResult = 0; - if ( aSlotName.equalsAscii( "ExportTo" ) ) + if ( aSlotName.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "ExportTo" ) ) ) nResult = EXPORT_REQUESTED; - else if ( aSlotName.equalsAscii( "ExportToPDF" ) ) + else if ( aSlotName.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "ExportToPDF" ) ) ) nResult = EXPORT_REQUESTED | PDFEXPORT_REQUESTED; - else if ( aSlotName.equalsAscii( "ExportDirectToPDF" ) ) + else if ( aSlotName.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "ExportDirectToPDF" ) ) ) nResult = EXPORT_REQUESTED | PDFEXPORT_REQUESTED | PDFDIRECTEXPORT_REQUESTED; - else if ( aSlotName.equalsAscii( "Save" ) ) + else if ( aSlotName.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "Save" ) ) ) nResult = SAVE_REQUESTED; - else if ( aSlotName.equalsAscii( "SaveAs" ) ) + else if ( aSlotName.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "SaveAs" ) ) ) nResult = SAVEAS_REQUESTED; else throw task::ErrorCodeIOException( ::rtl::OUString(), @@ -882,11 +882,11 @@ sal_Bool ModelData_Impl::OutputFileDialog( sal_Int8 nStoreMode, pFileDlg = new sfx2::FileDialogHelper( aDialogMode, aDialogFlags, aDocServiceName, nDialog, nMust, nDont, rStandardDir, rBlackList ); } - if( aDocServiceName.equalsAscii( "com.sun.star.drawing.DrawingDocument" ) ) + if( aDocServiceName.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "com.sun.star.drawing.DrawingDocument" ) ) ) eCtxt = sfx2::FileDialogHelper::SD_EXPORT; - if( aDocServiceName.equalsAscii( "com.sun.star.presentation.PresentationDocument" ) ) + if( aDocServiceName.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "com.sun.star.presentation.PresentationDocument" ) ) ) eCtxt = sfx2::FileDialogHelper::SI_EXPORT; - if( aDocServiceName.equalsAscii( "com.sun.star.text.TextDocument" ) ) + if( aDocServiceName.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "com.sun.star.text.TextDocument" ) ) ) eCtxt = sfx2::FileDialogHelper::SW_EXPORT; if ( eCtxt != sfx2::FileDialogHelper::UNKNOWN_CONTEXT ) diff --git a/sfx2/source/doc/objstor.cxx b/sfx2/source/doc/objstor.cxx index 86c46f3567..69861e3697 100644 --- a/sfx2/source/doc/objstor.cxx +++ b/sfx2/source/doc/objstor.cxx @@ -2957,9 +2957,9 @@ sal_Bool SfxObjectShell::IsInformationLost() ::rtl::OUString aPreusedFilterName; for ( sal_Int32 nInd = 0; nInd < aProps.getLength(); nInd++ ) { - if ( aProps[nInd].Name.equalsAscii( "FilterName" ) ) + if ( aProps[nInd].Name.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "FilterName" ) ) ) aProps[nInd].Value >>= aFilterName; - else if ( aProps[nInd].Name.equalsAscii( "PreusedFilterName" ) ) + else if ( aProps[nInd].Name.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "PreusedFilterName" ) ) ) aProps[nInd].Value >>= aPreusedFilterName; } @@ -3559,7 +3559,7 @@ sal_Bool SfxObjectShell::CopyStoragesOfUnknownMediaType( const uno::Reference< e default: { OSL_ENSURE( - aSubElements[nInd].equalsAscii( "Configurations2" ) || !xTarget->hasByName( aSubElements[nInd] ), + aSubElements[nInd].equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "Configurations2" ) ) || !xTarget->hasByName( aSubElements[nInd] ), "The target storage is an output storage, the element should not exist in the target!\n" ); if ( !xTarget->hasByName( aSubElements[nInd] ) ) diff --git a/sfx2/source/doc/plugin.cxx b/sfx2/source/doc/plugin.cxx index a8a6cb49d2..cb7c8100ef 100644 --- a/sfx2/source/doc/plugin.cxx +++ b/sfx2/source/doc/plugin.cxx @@ -206,15 +206,15 @@ uno::Reference< beans::XPropertySetInfo > SAL_CALL PluginObject::getPropertySetI void SAL_CALL PluginObject::setPropertyValue(const ::rtl::OUString& aPropertyName, const uno::Any& aAny) throw ( beans::UnknownPropertyException, beans::PropertyVetoException, lang::IllegalArgumentException, lang::WrappedTargetException, uno::RuntimeException) { - if ( aPropertyName.equalsAscii("PluginURL") ) + if ( aPropertyName.equalsAsciiL(RTL_CONSTASCII_STRINGPARAM("PluginURL")) ) { aAny >>= maURL; } - else if ( aPropertyName.equalsAscii("PluginMimeType") ) + else if ( aPropertyName.equalsAsciiL(RTL_CONSTASCII_STRINGPARAM("PluginMimeType")) ) { aAny >>= maMimeType; } - else if ( aPropertyName.equalsAscii("PluginCommands") ) + else if ( aPropertyName.equalsAsciiL(RTL_CONSTASCII_STRINGPARAM("PluginCommands")) ) { maCmdList.Clear(); uno::Sequence < beans::PropertyValue > aCommandSequence; @@ -229,15 +229,15 @@ uno::Any SAL_CALL PluginObject::getPropertyValue(const ::rtl::OUString& aPropert throw ( beans::UnknownPropertyException, lang::WrappedTargetException, uno::RuntimeException) { uno::Any aAny; - if ( aPropertyName.equalsAscii("PluginURL") ) + if ( aPropertyName.equalsAsciiL(RTL_CONSTASCII_STRINGPARAM("PluginURL")) ) { aAny <<= maURL; } - else if ( aPropertyName.equalsAscii("PluginMimeType") ) + else if ( aPropertyName.equalsAsciiL(RTL_CONSTASCII_STRINGPARAM("PluginMimeType")) ) { aAny <<= maMimeType; } - else if ( aPropertyName.equalsAscii("PluginCommands") ) + else if ( aPropertyName.equalsAsciiL(RTL_CONSTASCII_STRINGPARAM("PluginCommands")) ) { uno::Sequence< beans::PropertyValue > aCommandSequence; maCmdList.FillSequence( aCommandSequence ); diff --git a/sfx2/source/doc/sfxmodelfactory.cxx b/sfx2/source/doc/sfxmodelfactory.cxx index a22671c8d0..2b7c114484 100644 --- a/sfx2/source/doc/sfxmodelfactory.cxx +++ b/sfx2/source/doc/sfxmodelfactory.cxx @@ -149,9 +149,9 @@ namespace sfx2 { static bool isSpecialArgumentName( const ::rtl::OUString& _rValueName ) { - return _rValueName.equalsAscii( "EmbeddedObject" ) - || _rValueName.equalsAscii( "EmbeddedScriptSupport" ) - || _rValueName.equalsAscii( "DocumentRecoverySupport" ); + return _rValueName.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "EmbeddedObject" ) ) + || _rValueName.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "EmbeddedScriptSupport" ) ) + || _rValueName.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "DocumentRecoverySupport" ) ); } bool operator()( const Any& _rArgument ) const diff --git a/sfx2/source/toolbox/tbxitem.cxx b/sfx2/source/toolbox/tbxitem.cxx index f43cf8e8ed..2149566de7 100644 --- a/sfx2/source/toolbox/tbxitem.cxx +++ b/sfx2/source/toolbox/tbxitem.cxx @@ -1607,7 +1607,7 @@ SfxPopupWindow* SfxAppToolBoxControl_Impl::CreatePopupWindow() if ( !pMenu ) { ::framework::MenuConfiguration aConf( m_xServiceManager ); - if ( m_aCommandURL.equalsAscii( ".uno:AddDirect" )) + if ( m_aCommandURL.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( ".uno:AddDirect" ) )) pMenu = aConf.CreateBookmarkMenu( m_xFrame, BOOKMARK_NEWMENU ); else pMenu = aConf.CreateBookmarkMenu( m_xFrame, BOOKMARK_WIZARDMENU ); diff --git a/sfx2/source/view/ipclient.cxx b/sfx2/source/view/ipclient.cxx index dd9c1b6cd5..62c3957718 100644 --- a/sfx2/source/view/ipclient.cxx +++ b/sfx2/source/view/ipclient.cxx @@ -219,7 +219,7 @@ void SAL_CALL SfxInPlaceClient_Impl::notifyEvent( const document::EventObject& a { SolarMutexGuard aGuard; - if ( m_pClient && aEvent.EventName.equalsAscii("OnVisAreaChanged") && m_nAspect != embed::Aspects::MSOLE_ICON ) + if ( m_pClient && aEvent.EventName.equalsAsciiL(RTL_CONSTASCII_STRINGPARAM("OnVisAreaChanged")) && m_nAspect != embed::Aspects::MSOLE_ICON ) { m_pClient->ViewChanged(); m_pClient->Invalidate(); diff --git a/sfx2/source/view/viewfrm.cxx b/sfx2/source/view/viewfrm.cxx index 820b8d6aff..93a951d144 100644 --- a/sfx2/source/view/viewfrm.cxx +++ b/sfx2/source/view/viewfrm.cxx @@ -2579,7 +2579,7 @@ sal_Bool impl_maxOpenDocCountReached() continue; // a) do not count the help window - if (xFrame->getName().equalsAscii("OFFICE_HELP_TASK")) + if (xFrame->getName().equalsAsciiL(RTL_CONSTASCII_STRINGPARAM("OFFICE_HELP_TASK"))) continue; // b) count all other frames diff --git a/sfx2/source/view/viewfrm2.cxx b/sfx2/source/view/viewfrm2.cxx index a85c3fc200..0affb3b591 100644 --- a/sfx2/source/view/viewfrm2.cxx +++ b/sfx2/source/view/viewfrm2.cxx @@ -129,7 +129,7 @@ static String _getTabString() Sequence< NamedValue > sMaterial; if (xHolder->getMaterial() >>= sMaterial) { for (int i=0; i < sMaterial.getLength(); i++) { - if ((sMaterial[i].Name.equalsAscii("title")) && + if ((sMaterial[i].Name.equalsAsciiL(RTL_CONSTASCII_STRINGPARAM("title"))) && (sMaterial[i].Value >>= aTabString)) { result += ' '; diff --git a/sfx2/source/view/viewprn.cxx b/sfx2/source/view/viewprn.cxx index abca884afd..ce2093c596 100644 --- a/sfx2/source/view/viewprn.cxx +++ b/sfx2/source/view/viewprn.cxx @@ -150,7 +150,7 @@ SfxPrinterController::SfxPrinterController( const Any& i_rComplete, int nProps = aRenderParms.getLength(); for( int i = 0; i < nProps; i++ ) { - if( aRenderParms[i].Name.equalsAscii( "ExtraPrintUIOptions" ) ) + if( aRenderParms[i].Name.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "ExtraPrintUIOptions" ) ) ) { Sequence< beans::PropertyValue > aUIProps; aRenderParms[i].Value >>= aUIProps; @@ -749,18 +749,18 @@ void SfxViewShell::ExecPrint_Impl( SfxRequest &rReq ) TransformItems( nId, *rReq.GetArgs(), aProps, GetInterface()->GetSlot(nId) ); for ( sal_Int32 nProp=0; nProp<aProps.getLength(); nProp++ ) { - if ( aProps[nProp].Name.equalsAscii("Copies") ) + if ( aProps[nProp].Name.equalsAsciiL(RTL_CONSTASCII_STRINGPARAM("Copies")) ) aProps[nProp]. Name = rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("CopyCount")); - else if ( aProps[nProp].Name.equalsAscii("RangeText") ) + else if ( aProps[nProp].Name.equalsAsciiL(RTL_CONSTASCII_STRINGPARAM("RangeText")) ) aProps[nProp]. Name = rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("Pages")); - if ( aProps[nProp].Name.equalsAscii("Asynchron") ) + if ( aProps[nProp].Name.equalsAsciiL(RTL_CONSTASCII_STRINGPARAM("Asynchron")) ) { aProps[nProp]. Name = rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("Wait")); sal_Bool bAsynchron = sal_False; aProps[nProp].Value >>= bAsynchron; aProps[nProp].Value <<= (sal_Bool) (!bAsynchron); } - if ( aProps[nProp].Name.equalsAscii("Silent") ) + if ( aProps[nProp].Name.equalsAsciiL(RTL_CONSTASCII_STRINGPARAM("Silent")) ) { aProps[nProp]. Name = rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("MonitorVisible")); sal_Bool bPrintSilent = sal_False; diff --git a/sfx2/source/view/viewsh.cxx b/sfx2/source/view/viewsh.cxx index c47a546450..428a5db02e 100644 --- a/sfx2/source/view/viewsh.cxx +++ b/sfx2/source/view/viewsh.cxx @@ -222,7 +222,7 @@ static ::rtl::OUString RetrieveLabelFromCommand( { 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; @@ -321,32 +321,32 @@ enum ETypeFamily { case E_MS_DOC: { - if (sModule.equalsAscii( "com.sun.star.text.TextDocument" )) + if (sModule.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "com.sun.star.text.TextDocument" ) )) sType = ::rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( "writer_MS_Word_97" )); else - if (sModule.equalsAscii( "com.sun.star.sheet.SpreadsheetDocument" )) + if (sModule.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "com.sun.star.sheet.SpreadsheetDocument" ) )) sType = ::rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( "calc_MS_Excel_97" )); else - if (sModule.equalsAscii( "com.sun.star.drawing.DrawingDocument" )) + if (sModule.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "com.sun.star.drawing.DrawingDocument" ) )) sType = ::rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( "impress_MS_PowerPoint_97" )); else - if (sModule.equalsAscii( "com.sun.star.presentation.PresentationDocument" )) + if (sModule.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "com.sun.star.presentation.PresentationDocument" ) )) sType = ::rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( "impress_MS_PowerPoint_97" )); } break; case E_OOO_DOC: { - if (sModule.equalsAscii( "com.sun.star.text.TextDocument" )) + if (sModule.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "com.sun.star.text.TextDocument" ) )) sType = ::rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( "writer8" )); else - if (sModule.equalsAscii( "com.sun.star.sheet.SpreadsheetDocument" )) + if (sModule.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "com.sun.star.sheet.SpreadsheetDocument" ) )) sType = ::rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( "calc8" )); else - if (sModule.equalsAscii( "com.sun.star.drawing.DrawingDocument" )) + if (sModule.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "com.sun.star.drawing.DrawingDocument" ) )) sType = ::rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( "draw8" )); else - if (sModule.equalsAscii( "com.sun.star.presentation.PresentationDocument" )) + if (sModule.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "com.sun.star.presentation.PresentationDocument" ) )) sType = ::rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( "impress8" )); } break; diff --git a/sfx2/workben/custompanel/ctp_factory.cxx b/sfx2/workben/custompanel/ctp_factory.cxx index 4d6f12d527..419671da51 100644 --- a/sfx2/workben/custompanel/ctp_factory.cxx +++ b/sfx2/workben/custompanel/ctp_factory.cxx @@ -95,7 +95,7 @@ namespace sd { namespace colortoolpanel const PropertyValue* pArgEnd = i_rArgs.getConstArray() + i_rArgs.getLength(); for ( ; pArg != pArgEnd; ++pArg ) { - if ( pArg->Name.equalsAscii( "ParentWindow" ) ) + if ( pArg->Name.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "ParentWindow" ) ) ) { xParentWindow.set( pArg->Value, UNO_QUERY ); break; |