diff options
author | Swachhand Lokhande <swachhandl95@gmail.com> | 2015-03-07 18:58:49 +0530 |
---|---|---|
committer | Miklos Vajna <vmiklos@collabora.co.uk> | 2015-03-10 10:26:59 +0000 |
commit | b1534edf523a405b91ad04c5351735e745ceb7ee (patch) | |
tree | 936b938dab11100b532f3b9204891d162c334bef /basctl/source/basicide/moduldl2.cxx | |
parent | bb2728fd246716588d135c9e159135b1c5a7d3e1 (diff) |
tdf#89592 Using initializer_lists to populate Sequence<PropertyValue>
Change-Id: Idef9dd55eb1719eaf592bc4a86440cbd5aa4fb32
Reviewed-on: https://gerrit.libreoffice.org/14781
Reviewed-by: Miklos Vajna <vmiklos@collabora.co.uk>
Tested-by: Miklos Vajna <vmiklos@collabora.co.uk>
Diffstat (limited to 'basctl/source/basicide/moduldl2.cxx')
-rw-r--r-- | basctl/source/basicide/moduldl2.cxx | 11 |
1 files changed, 5 insertions, 6 deletions
diff --git a/basctl/source/basicide/moduldl2.cxx b/basctl/source/basicide/moduldl2.cxx index 812c9ec1fa03..786574e8365c 100644 --- a/basctl/source/basicide/moduldl2.cxx +++ b/basctl/source/basicide/moduldl2.cxx @@ -52,6 +52,7 @@ #include <com/sun/star/util/VetoException.hpp> #include <com/sun/star/script/ModuleSizeExceededRequest.hpp> +#include <comphelper/propertysequence.hxx> namespace basctl @@ -1220,14 +1221,12 @@ void LibPage::ExportAsPackage( const OUString& aLibName ) const OUString strFullPath = "FullPath" ; const OUString strBasicMediaType = "application/vnd.sun.star.basic-library" ; - Sequence<beans::PropertyValue> attribs( 2 ); - beans::PropertyValue * pattribs = attribs.getArray(); - pattribs[ 0 ].Name = strFullPath; OUString fullPath = aLibName; fullPath += "/" ; - pattribs[ 0 ].Value <<= fullPath; - pattribs[ 1 ].Name = strMediaType; - pattribs[ 1 ].Value <<= strBasicMediaType; + auto attribs(::comphelper::InitPropertySequence({ + { strFullPath, makeAny(fullPath) }, + { strMediaType, makeAny(strBasicMediaType) } + })); manifest.push_back( attribs ); // write into pipe: |