diff options
author | Noel Grandin <noel@peralex.com> | 2015-11-06 09:23:33 +0200 |
---|---|---|
committer | Noel Grandin <noelgrandin@gmail.com> | 2015-11-09 08:34:40 +0000 |
commit | 6c80a8fe89fadf9a2c7260a09c037a09462f53d1 (patch) | |
tree | d36da9ee2a5fdc579d2a57ff6ba02deaddfa785a /desktop | |
parent | e1fc599eb764186e5d511ace9785463eebbc7028 (diff) |
new loplugin: oncevar
Change-Id: If57390510dde4d166be3141b9f658a7453755d3f
Reviewed-on: https://gerrit.libreoffice.org/19815
Tested-by: Jenkins <ci@libreoffice.org>
Reviewed-by: Noel Grandin <noelgrandin@gmail.com>
Diffstat (limited to 'desktop')
-rw-r--r-- | desktop/source/lib/init.cxx | 3 | ||||
-rw-r--r-- | desktop/source/splash/splash.cxx | 6 | ||||
-rw-r--r-- | desktop/source/splash/unxsplash.cxx | 4 |
3 files changed, 5 insertions, 8 deletions
diff --git a/desktop/source/lib/init.cxx b/desktop/source/lib/init.cxx index aaa5492087c7..2d545caa544d 100644 --- a/desktop/source/lib/init.cxx +++ b/desktop/source/lib/init.cxx @@ -1100,9 +1100,8 @@ static bool doc_paste(LibreOfficeKitDocument* pThis, const char* pMimeType, cons return false; } - OUString aCommand(".uno:Paste"); uno::Sequence<beans::PropertyValue> aPropertyValues; - if (!comphelper::dispatchCommand(aCommand, aPropertyValues)) + if (!comphelper::dispatchCommand(".uno:Paste", aPropertyValues)) { gImpl->maLastExceptionMsg = "Failed to dispatch the .uno: command"; return false; diff --git a/desktop/source/splash/splash.cxx b/desktop/source/splash/splash.cxx index c933dcf9f396..bf69ff2686c1 100644 --- a/desktop/source/splash/splash.cxx +++ b/desktop/source/splash/splash.cxx @@ -687,9 +687,9 @@ OUString desktop::splash::getImplementationName() { return OUString("com.sun.star.office.comp.SplashScreen"); } -css::uno::Sequence< OUString > desktop::splash::getSupportedServiceNames() { - OUString name("com.sun.star.office.SplashScreen"); - return css::uno::Sequence< OUString >(&name, 1); +css::uno::Sequence< OUString > desktop::splash::getSupportedServiceNames() +{ + return Sequence< OUString > { "com.sun.star.office.SplashScreen" }; } /* vim:set shiftwidth=4 softtabstop=4 expandtab: */ diff --git a/desktop/source/splash/unxsplash.cxx b/desktop/source/splash/unxsplash.cxx index 1170e84b97e8..13daaefb714c 100644 --- a/desktop/source/splash/unxsplash.cxx +++ b/desktop/source/splash/unxsplash.cxx @@ -163,9 +163,7 @@ OUString UnxSplash_getImplementationName() uno::Sequence< OUString > UnxSplash_getSupportedServiceNames() throw() { - const OUString aServiceName( "com.sun.star.office.PipeSplashScreen" ); - const uno::Sequence< OUString > aSeq( &aServiceName, 1 ); - return aSeq; + return uno::Sequence< OUString > { "com.sun.star.office.PipeSplashScreen" }; } /* vim:set shiftwidth=4 softtabstop=4 expandtab: */ |