summaryrefslogtreecommitdiff
path: root/desktop/source/app/appinit.cxx
diff options
context:
space:
mode:
authorStephan Bergmann <sbergman@redhat.com>2014-12-12 17:51:36 +0100
committerStephan Bergmann <sbergman@redhat.com>2014-12-12 17:51:36 +0100
commit9d94148b0429acf77880742c0569bbebddd794f9 (patch)
treec00c90f36e6703c437dc9057ab55cb624633c343 /desktop/source/app/appinit.cxx
parentbca00da68640bb052c1628270ce3924b7228d7b8 (diff)
desktop: Use appropriate OUString functions on string constants
Change-Id: I5791c212a103fe9c2a5376545944a70454b28bdd
Diffstat (limited to 'desktop/source/app/appinit.cxx')
-rw-r--r--desktop/source/app/appinit.cxx12
1 files changed, 5 insertions, 7 deletions
diff --git a/desktop/source/app/appinit.cxx b/desktop/source/app/appinit.cxx
index 02478a4b7450..797ea9c84a74 100644
--- a/desktop/source/app/appinit.cxx
+++ b/desktop/source/app/appinit.cxx
@@ -234,7 +234,7 @@ void Desktop::destroyAcceptor(const OUString& aAcceptString)
{
// special case stop all acceptors
AcceptorMap &rMap = acceptorMap::get();
- if (aAcceptString.equalsAscii("all")) {
+ if (aAcceptString == "all") {
rMap.clear();
} else {
@@ -283,9 +283,8 @@ void Desktop::CreateTemporaryDirectory()
}
// set temp base directory
- sal_Int32 nLength = aTempBaseURL.getLength();
- if ( aTempBaseURL.matchAsciiL( "/", 1, nLength-1 ) )
- aTempBaseURL = aTempBaseURL.copy( 0, nLength - 1 );
+ if ( aTempBaseURL.endsWith( "/" ) )
+ aTempBaseURL = aTempBaseURL.copy( 0, aTempBaseURL.getLength() - 1 );
OUString aRet;
OUString aTempPath( aTempBaseURL );
@@ -298,9 +297,8 @@ void Desktop::CreateTemporaryDirectory()
{
::osl::File::getTempDirURL( aTempBaseURL );
- nLength = aTempBaseURL.getLength();
- if ( aTempBaseURL.matchAsciiL( "/", 1, nLength-1 ) )
- aTempBaseURL = aTempBaseURL.copy( 0, nLength - 1 );
+ if ( aTempBaseURL.endsWith( "/" ) )
+ aTempBaseURL = aTempBaseURL.copy( 0, aTempBaseURL.getLength() - 1 );
aTempPath = aTempBaseURL;
::osl::FileBase::getFileURLFromSystemPath( aRet, aTempPath );