diff options
author | Noel Grandin <noel@peralex.com> | 2013-11-21 15:52:45 +0200 |
---|---|---|
committer | Noel Grandin <noel@peralex.com> | 2013-11-22 08:07:19 +0200 |
commit | 73342dbb82ba074d01962359dac50fb2aa36cbeb (patch) | |
tree | addab0397681725810b42ad55ab15be3fdb4c236 /sfx2 | |
parent | 071c3f3e93c4c00cf57ce3c382325cd717fed511 (diff) |
remove unnecessary RTL_CONSTASCII_STRINGPARAM
A final pass through the code, converting code to use the new
OUString and OString methods that can detect string literals.
Change-Id: Ifa6382335e5650a1c67e52006b26354e0692c710
Diffstat (limited to 'sfx2')
-rw-r--r-- | sfx2/source/doc/DocumentMetadataAccess.cxx | 3 | ||||
-rw-r--r-- | sfx2/source/doc/objmisc.cxx | 2 | ||||
-rw-r--r-- | sfx2/source/sidebar/ResourceManager.cxx | 3 | ||||
-rw-r--r-- | sfx2/source/view/frmload.cxx | 2 |
4 files changed, 4 insertions, 6 deletions
diff --git a/sfx2/source/doc/DocumentMetadataAccess.cxx b/sfx2/source/doc/DocumentMetadataAccess.cxx index 1b823cc42893..7eba5b092fb7 100644 --- a/sfx2/source/doc/DocumentMetadataAccess.cxx +++ b/sfx2/source/doc/DocumentMetadataAccess.cxx @@ -132,8 +132,7 @@ uno::Reference<rdf::XURI> createBaseURI( // #i108078# workaround non-hierarchical vnd.sun.star.expand URIs // this really should be done somewhere else, not here. OUString pkgURI(i_rPkgURI); - if (pkgURI.matchIgnoreAsciiCaseAsciiL( - RTL_CONSTASCII_STRINGPARAM("vnd.sun.star.expand:"))) + if (pkgURI.matchIgnoreAsciiCase("vnd.sun.star.expand:")) { // expand it here (makeAbsolute requires hierarchical URI) pkgURI = pkgURI.copy( RTL_CONSTASCII_LENGTH("vnd.sun.star.expand:") ); diff --git a/sfx2/source/doc/objmisc.cxx b/sfx2/source/doc/objmisc.cxx index 4285fafe8f2a..357ebe6f6c71 100644 --- a/sfx2/source/doc/objmisc.cxx +++ b/sfx2/source/doc/objmisc.cxx @@ -1512,7 +1512,7 @@ ErrCode SfxObjectShell::CallXScript( const Reference< XInterface >& _rxScriptCon OSL_TRACE( "in CallXScript" ); ErrCode nErr = ERRCODE_NONE; - bool bIsDocumentScript = ( _rScriptURL.indexOfAsciiL( RTL_CONSTASCII_STRINGPARAM( "location=document" ) ) >= 0 ); + bool bIsDocumentScript = ( _rScriptURL.indexOf( "location=document" ) >= 0 ); // TODO: we should parse the URL, and check whether there is a parameter with this name. // Otherwise, we might find too much. if ( bIsDocumentScript && !lcl_isScriptAccessAllowed_nothrow( _rxScriptContext ) ) diff --git a/sfx2/source/sidebar/ResourceManager.cxx b/sfx2/source/sidebar/ResourceManager.cxx index 5900b3efff9a..d3088907f847 100644 --- a/sfx2/source/sidebar/ResourceManager.cxx +++ b/sfx2/source/sidebar/ResourceManager.cxx @@ -636,8 +636,7 @@ void ResourceManager::GetToolPanelNodeNames ( const sal_Int32 nCount (aChildNodeNames.getLength()); for (sal_Int32 nIndex(0); nIndex<nCount; ++nIndex) { - if (aChildNodeNames[nIndex].matchAsciiL( - RTL_CONSTASCII_STRINGPARAM( "private:resource/toolpanel/"))) + if (aChildNodeNames[nIndex].startsWith( "private:resource/toolpanel/" )) rMatchingNames.push_back(aChildNodeNames[nIndex]); } } diff --git a/sfx2/source/view/frmload.cxx b/sfx2/source/view/frmload.cxx index 25d6a958714f..4c0560d4c5c2 100644 --- a/sfx2/source/view/frmload.cxx +++ b/sfx2/source/view/frmload.cxx @@ -368,7 +368,7 @@ sal_uInt16 SfxFrameLoader_Impl::impl_findSlotParam( const OUString& i_rFactoryUR if ( nParamPos >= 0 ) { // currently only the "slot" parameter is supported - const sal_Int32 nSlotPos = i_rFactoryURL.indexOfAsciiL( RTL_CONSTASCII_STRINGPARAM( "slot=" ), nParamPos ); + const sal_Int32 nSlotPos = i_rFactoryURL.indexOf( "slot=", nParamPos ); if ( nSlotPos > 0 ) sSlotParam = i_rFactoryURL.copy( nSlotPos + 5 ); } |