summaryrefslogtreecommitdiff
path: root/extensions/source/abpilot/admininvokationimpl.cxx
diff options
context:
space:
mode:
Diffstat (limited to 'extensions/source/abpilot/admininvokationimpl.cxx')
-rw-r--r--extensions/source/abpilot/admininvokationimpl.cxx19
1 files changed, 7 insertions, 12 deletions
diff --git a/extensions/source/abpilot/admininvokationimpl.cxx b/extensions/source/abpilot/admininvokationimpl.cxx
index d0d183985f5b..7253d400fbc5 100644
--- a/extensions/source/abpilot/admininvokationimpl.cxx
+++ b/extensions/source/abpilot/admininvokationimpl.cxx
@@ -23,6 +23,7 @@
#include <com/sun/star/ui/dialogs/XExecutableDialog.hpp>
#include <com/sun/star/awt/XWindow.hpp>
#include <com/sun/star/sdbc/DriverManager.hpp>
+#include <comphelper/propertysequence.hxx>
#include <vcl/stdtext.hxx>
#include <toolkit/helper/vclunohelper.hxx>
#include "strings.hrc"
@@ -66,19 +67,13 @@ namespace abp
static const char s_sDataSourceTypeChangeDialog[] = "com.sun.star.sdb.DataSourceTypeChangeDialog";
// the parameters for the call
- Sequence< Any > aArguments(3);
- Any* pArguments = aArguments.getArray();
-
- // the parent window
- Reference< XWindow > xDialogParent = VCLUnoHelper::GetInterface(m_pMessageParent);
- *pArguments++ <<= PropertyValue("ParentWindow", -1, makeAny(xDialogParent), PropertyState_DIRECT_VALUE);
-
- // the title of the dialog
- OUString sAdminDialogTitle(compmodule::ModuleRes(RID_STR_ADMINDIALOGTITLE));
- *pArguments++ <<= PropertyValue("Title", -1, makeAny(sAdminDialogTitle), PropertyState_DIRECT_VALUE);
+ Sequence<Any> aArguments(comphelper::InitAnyPropertySequence(
+ {
+ {"ParentWindow", Any(VCLUnoHelper::GetInterface(m_pMessageParent))},
+ {"Title", Any(compmodule::ModuleRes(RID_STR_ADMINDIALOGTITLE))},
+ {"InitialSelection", Any(m_xDataSource)}, // the name of the new data source
+ }));
- // the name of the new data source
- *pArguments++ <<= PropertyValue("InitialSelection", -1, makeAny(m_xDataSource), PropertyState_DIRECT_VALUE);
// create the dialog
Reference< XExecutableDialog > xDialog;