summaryrefslogtreecommitdiff
path: root/svtools/source/uno
diff options
context:
space:
mode:
authorNoel Grandin <noelgrandin@gmail.com>2015-11-15 12:17:19 +0200
committerNoel Grandin <noelgrandin@gmail.com>2015-11-15 11:31:23 +0000
commit54d22957bc241fc5867fa1c720cf1266133e4e90 (patch)
treea94c9008ccbe953226a479a875e01119d77d9402 /svtools/source/uno
parent8e234c5b7d5bae66c544e581bee5770f3f83dd81 (diff)
use initialiser for Sequence<OUString>
performed using: git grep -lP 'Sequence.*OUString.*\(1\)' | xargs perl -0777 -pi -e "s/Sequence<OUString> (\w+)\(1\); .*\[0\] = (\S+);/Sequence<OUString> \1 { \2 };/g" Change-Id: I4da56c80fa09bfc1e8f868794001e9921431e09f Reviewed-on: https://gerrit.libreoffice.org/19968 Reviewed-by: Noel Grandin <noelgrandin@gmail.com> Tested-by: Noel Grandin <noelgrandin@gmail.com>
Diffstat (limited to 'svtools/source/uno')
-rw-r--r--svtools/source/uno/addrtempuno.cxx3
-rw-r--r--svtools/source/uno/unoevent.cxx3
2 files changed, 2 insertions, 4 deletions
diff --git a/svtools/source/uno/addrtempuno.cxx b/svtools/source/uno/addrtempuno.cxx
index 10e94851dc40..4ffafea5f4f5 100644
--- a/svtools/source/uno/addrtempuno.cxx
+++ b/svtools/source/uno/addrtempuno.cxx
@@ -101,8 +101,7 @@ namespace {
css::uno::Sequence<OUString> SAL_CALL OAddressBookSourceDialogUno::getSupportedServiceNames() throw(RuntimeException, std::exception)
{
- css::uno::Sequence<OUString> aSupported(1);
- aSupported.getArray()[0] = "com.sun.star.ui.AddressBookSourceDialog";
+ css::uno::Sequence<OUString> aSupported { "com.sun.star.ui.AddressBookSourceDialog" };
return aSupported;
}
diff --git a/svtools/source/uno/unoevent.cxx b/svtools/source/uno/unoevent.cxx
index b5b4d21461b4..56e6ccb93b56 100644
--- a/svtools/source/uno/unoevent.cxx
+++ b/svtools/source/uno/unoevent.cxx
@@ -151,8 +151,7 @@ sal_Bool SvBaseEventDescriptor::supportsService(const OUString& rServiceName)
Sequence<OUString> SvBaseEventDescriptor::getSupportedServiceNames()
throw(RuntimeException, std::exception)
{
- Sequence<OUString> aSequence(1);
- aSequence[0] = sServiceName;
+ Sequence<OUString> aSequence { sServiceName };
return aSequence;
}