summaryrefslogtreecommitdiff
path: root/sfx2
diff options
context:
space:
mode:
authorNoel Grandin <noel@peralex.com>2013-11-19 17:06:06 +0200
committerNoel Grandin <noel@peralex.com>2013-11-20 10:07:32 +0200
commit52bbd9cc00b5a1e15e4f96b5c5fa5e75855692c1 (patch)
tree72d0d1d16806f1c785a4f79ea2c0cdfe54bb8101 /sfx2
parent3af99e4d59d89c343965a928681a30f36b1007d2 (diff)
remove unnecessary RTL_CONSTASCII_STRINGPARAM in appendAscii calls
Convert code like: aStrBuf.appendAscii( RTL_CONSTASCII_STRINGPARAM( "ln(x)" )); to: aStrBuf.append( "ln(x)" ); which compiles down to the same code. Change-Id: I24c7cb45ceb32fd7cd6ec7ed203c2a5d746f1c5c
Diffstat (limited to 'sfx2')
-rw-r--r--sfx2/source/appl/appserv.cxx2
-rw-r--r--sfx2/source/appl/sfxpicklist.cxx6
-rw-r--r--sfx2/source/dialog/filedlghelper.cxx8
-rw-r--r--sfx2/source/dialog/taskpane.cxx7
-rw-r--r--sfx2/source/doc/docfac.cxx4
-rw-r--r--sfx2/source/view/viewfac.cxx2
-rw-r--r--sfx2/source/view/viewfrm.cxx6
-rw-r--r--sfx2/source/view/viewsh.cxx2
8 files changed, 18 insertions, 19 deletions
diff --git a/sfx2/source/appl/appserv.cxx b/sfx2/source/appl/appserv.cxx
index 27abf6c80394..7fc357a4fbd8 100644
--- a/sfx2/source/appl/appserv.cxx
+++ b/sfx2/source/appl/appserv.cxx
@@ -1052,7 +1052,7 @@ void SfxApplication::OfaExec_Impl( SfxRequest& rReq )
if ( xSystemShell.is() && !sTemplRepoURL.isEmpty() )
{
OUStringBuffer aURLBuf( sTemplRepoURL );
- aURLBuf.appendAscii(RTL_CONSTASCII_STRINGPARAM("?lang="));
+ aURLBuf.append("?lang=");
// read locale from configuration
OUString sLocale(officecfg::Setup::L10N::ooLocale::get());
diff --git a/sfx2/source/appl/sfxpicklist.cxx b/sfx2/source/appl/sfxpicklist.cxx
index 9ec4aa3fb435..4b5b3fd17a3c 100644
--- a/sfx2/source/appl/sfxpicklist.cxx
+++ b/sfx2/source/appl/sfxpicklist.cxx
@@ -82,10 +82,10 @@ void SfxPickList::CreatePicklistMenuTitle( Menu* pMenu, sal_uInt16 nItemId, cons
aPickEntry.append(OUString::number(nNo + 1));
}
else if ( nNo == 9 )
- aPickEntry.appendAscii(RTL_CONSTASCII_STRINGPARAM("1~0"));
+ aPickEntry.append("1~0");
else
aPickEntry.append(OUString::number(nNo + 1));
- aPickEntry.appendAscii(RTL_CONSTASCII_STRINGPARAM(": "));
+ aPickEntry.append(": ");
INetURLObject aURL( aURLString );
OUString aTipHelpText;
@@ -111,7 +111,7 @@ void SfxPickList::CreatePicklistMenuTitle( Menu* pMenu, sal_uInt16 nItemId, cons
if ( aPickEntry.getLength() > 50 )
{
aPickEntry.setLength( 47 );
- aPickEntry.appendAscii(RTL_CONSTASCII_STRINGPARAM("..."));
+ aPickEntry.append("...");
}
}
else
diff --git a/sfx2/source/dialog/filedlghelper.cxx b/sfx2/source/dialog/filedlghelper.cxx
index 26a5345a3573..c8178a4420f6 100644
--- a/sfx2/source/dialog/filedlghelper.cxx
+++ b/sfx2/source/dialog/filedlghelper.cxx
@@ -1762,12 +1762,12 @@ void FileDialogHelper_Impl::addFilters( const OUString& rFactory,
// create the list of filters
OUStringBuffer sQuery(256);
- sQuery.appendAscii(RTL_CONSTASCII_STRINGPARAM("getSortedFilterList()"));
- sQuery.appendAscii(RTL_CONSTASCII_STRINGPARAM(":module="));
+ sQuery.append("getSortedFilterList()");
+ sQuery.append(":module=");
sQuery.append(rFactory); // use long name here !
- sQuery.appendAscii(RTL_CONSTASCII_STRINGPARAM(":iflags="));
+ sQuery.append(":iflags=");
sQuery.append(OUString::number(m_nMustFlags));
- sQuery.appendAscii(RTL_CONSTASCII_STRINGPARAM(":eflags="));
+ sQuery.append(":eflags=");
sQuery.append(OUString::number(m_nDontFlags));
uno::Reference< XEnumeration > xResult;
diff --git a/sfx2/source/dialog/taskpane.cxx b/sfx2/source/dialog/taskpane.cxx
index 394f4bc0e7ba..12a7b1dcfd77 100644
--- a/sfx2/source/dialog/taskpane.cxx
+++ b/sfx2/source/dialog/taskpane.cxx
@@ -107,10 +107,9 @@ namespace sfx2
const OUString sWindowStateRef( aModuleProps.getOrDefault( "ooSetupFactoryWindowStateConfigRef", OUString() ) );
- aPathComposer.appendAscii(RTL_CONSTASCII_STRINGPARAM(
- "org.openoffice.Office.UI."));
+ aPathComposer.append( "org.openoffice.Office.UI." );
aPathComposer.append( sWindowStateRef );
- aPathComposer.appendAscii(RTL_CONSTASCII_STRINGPARAM("/UIElements/States"));
+ aPathComposer.append( "/UIElements/States" );
if ( !i_rResourceURL.isEmpty() )
{
aPathComposer.append('/').append( i_rResourceURL );
@@ -173,7 +172,7 @@ namespace sfx2
if ( sImageURL.startsWith( pCommandImagePrefix ) )
{
OUStringBuffer aCommandName;
- aCommandName.appendAscii(RTL_CONSTASCII_STRINGPARAM(".uno:"));
+ aCommandName.append( ".uno:" );
aCommandName.append( sImageURL.copy( nCommandImagePrefixLen ) );
const OUString sCommandName( aCommandName.makeStringAndClear() );
diff --git a/sfx2/source/doc/docfac.cxx b/sfx2/source/doc/docfac.cxx
index 5a27c50068b0..67de74486ea9 100644
--- a/sfx2/source/doc/docfac.cxx
+++ b/sfx2/source/doc/docfac.cxx
@@ -371,8 +371,8 @@ const SvGlobalName& SfxObjectFactory::GetClassId() const
OUString SfxObjectFactory::GetFactoryURL() const
{
OUStringBuffer aURLComposer;
- aURLComposer.appendAscii(RTL_CONSTASCII_STRINGPARAM("private:factory/"));
- aURLComposer.appendAscii(GetShortName());
+ aURLComposer.append("private:factory/");
+ aURLComposer.append(GetShortName());
return aURLComposer.makeStringAndClear();
}
diff --git a/sfx2/source/view/viewfac.cxx b/sfx2/source/view/viewfac.cxx
index 35926d3648e2..24b5eef7a7ef 100644
--- a/sfx2/source/view/viewfac.cxx
+++ b/sfx2/source/view/viewfac.cxx
@@ -34,7 +34,7 @@ SfxViewShell *SfxViewFactory::CreateInstance(SfxViewFrame *pFrame, SfxViewShell
OUString SfxViewFactory::GetLegacyViewName() const
{
OUStringBuffer aViewName;
- aViewName.appendAscii(RTL_CONSTASCII_STRINGPARAM("view"));
+ aViewName.append( "view" );
aViewName.append( sal_Int32( GetOrdinal() ) );
return aViewName.makeStringAndClear();
}
diff --git a/sfx2/source/view/viewfrm.cxx b/sfx2/source/view/viewfrm.cxx
index 1fa99c46c2f6..f29363bbad24 100644
--- a/sfx2/source/view/viewfrm.cxx
+++ b/sfx2/source/view/viewfrm.cxx
@@ -2726,11 +2726,11 @@ void SfxViewFrame::AddDispatchMacroToBasic_Impl( const OUString& sMacro )
}
// append new method
- sRoutine.appendAscii(RTL_CONSTASCII_STRINGPARAM("\nsub "));
+ sRoutine.append( "\nsub " );
sRoutine.append(sMacroName);
- sRoutine.appendAscii(RTL_CONSTASCII_STRINGPARAM("\n"));
+ sRoutine.append( "\n" );
sRoutine.append(sMacro);
- sRoutine.appendAscii(RTL_CONSTASCII_STRINGPARAM("\nend sub\n"));
+ sRoutine.append( "\nend sub\n" );
// create the modul inside the library and insert the macro routine
aTemp <<= sRoutine.makeStringAndClear();
diff --git a/sfx2/source/view/viewsh.cxx b/sfx2/source/view/viewsh.cxx
index c4d9eb47e1e7..695067007e28 100644
--- a/sfx2/source/view/viewsh.cxx
+++ b/sfx2/source/view/viewsh.cxx
@@ -816,7 +816,7 @@ void SfxViewShell::GetState_Impl( SfxItemSet &rSet )
aBuffer.append( RetrieveLabelFromCommand(
OUString( ".uno:PrintDefault" ),
xFrame ));
- aBuffer.appendAscii(RTL_CONSTASCII_STRINGPARAM(" ("));
+ aBuffer.append( " (" );
aBuffer.append( aPrinterName );
aBuffer.append(')');