summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--chart2/source/controller/dialogs/dlg_ChartType_UNO.cxx10
-rw-r--r--chart2/source/controller/inc/dlg_ChartType_UNO.hxx2
-rw-r--r--dbaccess/source/ui/inc/unosqlmessage.hxx2
-rw-r--r--dbaccess/source/ui/uno/AdvancedSettingsDlg.cxx8
-rw-r--r--dbaccess/source/ui/uno/DBTypeWizDlg.cxx4
-rw-r--r--dbaccess/source/ui/uno/DBTypeWizDlg.hxx2
-rw-r--r--dbaccess/source/ui/uno/DBTypeWizDlgSetup.cxx6
-rw-r--r--dbaccess/source/ui/uno/DBTypeWizDlgSetup.hxx2
-rw-r--r--dbaccess/source/ui/uno/TableFilterDlg.cxx4
-rw-r--r--dbaccess/source/ui/uno/TableFilterDlg.hxx2
-rw-r--r--dbaccess/source/ui/uno/UserSettingsDlg.cxx4
-rw-r--r--dbaccess/source/ui/uno/UserSettingsDlg.hxx2
-rw-r--r--dbaccess/source/ui/uno/admindlg.cxx4
-rw-r--r--dbaccess/source/ui/uno/admindlg.hxx2
-rw-r--r--dbaccess/source/ui/uno/composerdialogs.cxx16
-rw-r--r--dbaccess/source/ui/uno/composerdialogs.hxx2
-rw-r--r--dbaccess/source/ui/uno/copytablewizard.cxx8
-rw-r--r--dbaccess/source/ui/uno/textconnectionsettings_uno.cxx6
-rw-r--r--dbaccess/source/ui/uno/unoDirectSql.cxx6
-rw-r--r--dbaccess/source/ui/uno/unoDirectSql.hxx2
-rw-r--r--dbaccess/source/ui/uno/unoadmin.cxx4
-rw-r--r--dbaccess/source/ui/uno/unosqlmessage.cxx6
-rw-r--r--extensions/source/abpilot/unodialogabp.cxx6
-rw-r--r--extensions/source/abpilot/unodialogabp.hxx2
-rw-r--r--extensions/source/dbpilots/unoautopilot.hxx4
-rw-r--r--extensions/source/propctrlr/MasterDetailLinkDialog.cxx8
-rw-r--r--extensions/source/propctrlr/MasterDetailLinkDialog.hxx2
-rw-r--r--extensions/source/propctrlr/controlfontdialog.cxx14
-rw-r--r--extensions/source/propctrlr/controlfontdialog.hxx2
-rw-r--r--extensions/source/propctrlr/pcrunodialogs.cxx10
-rw-r--r--extensions/source/propctrlr/pcrunodialogs.hxx2
-rw-r--r--filter/source/flash/swfdialog.cxx8
-rw-r--r--filter/source/flash/swfdialog.hxx2
-rw-r--r--filter/source/pdf/pdfdialog.cxx10
-rw-r--r--filter/source/pdf/pdfdialog.hxx2
-rw-r--r--include/svtools/genericunodialog.hxx38
-rw-r--r--svtools/source/uno/addrtempuno.cxx13
-rw-r--r--svtools/source/uno/genericunodialog.cxx26
-rw-r--r--svtools/source/uno/wizard/unowizard.cxx44
-rw-r--r--svx/source/form/xfm_addcondition.cxx6
-rw-r--r--svx/source/inc/xfm_addcondition.hxx2
41 files changed, 135 insertions, 170 deletions
diff --git a/chart2/source/controller/dialogs/dlg_ChartType_UNO.cxx b/chart2/source/controller/dialogs/dlg_ChartType_UNO.cxx
index 1b2aa97aa766..51a3fa06ff3d 100644
--- a/chart2/source/controller/dialogs/dlg_ChartType_UNO.cxx
+++ b/chart2/source/controller/dialogs/dlg_ChartType_UNO.cxx
@@ -37,10 +37,10 @@ ChartTypeUnoDlg::~ChartTypeUnoDlg()
{
// we do this here cause the base class' call to destroyDialog won't reach us anymore: we're within a dtor,
// so this virtual-method-call the base class does not work, we're already dead then...
- if (m_aDialog)
+ if (m_xDialog)
{
::osl::MutexGuard aGuard(m_aMutex);
- if (m_aDialog)
+ if (m_xDialog)
destroyDialog();
}
}
@@ -71,10 +71,12 @@ void ChartTypeUnoDlg::implInitialize(const uno::Any& _rValue)
else
ChartTypeUnoDlg_BASE::implInitialize(_rValue);
}
-svt::OGenericUnoDialog::Dialog ChartTypeUnoDlg::createDialog(const css::uno::Reference<css::awt::XWindow>& rParent)
+
+std::unique_ptr<weld::DialogController> ChartTypeUnoDlg::createDialog(const css::uno::Reference<css::awt::XWindow>& rParent)
{
- return svt::OGenericUnoDialog::Dialog(std::make_unique<ChartTypeDialog>(Application::GetFrameWeld(rParent), m_xChartModel));
+ return std::make_unique<ChartTypeDialog>(Application::GetFrameWeld(rParent), m_xChartModel);
}
+
uno::Reference<beans::XPropertySetInfo> SAL_CALL ChartTypeUnoDlg::getPropertySetInfo()
{
return createPropertySetInfo( getInfoHelper() );
diff --git a/chart2/source/controller/inc/dlg_ChartType_UNO.hxx b/chart2/source/controller/inc/dlg_ChartType_UNO.hxx
index bc6c211205bc..6cadcd5e6573 100644
--- a/chart2/source/controller/inc/dlg_ChartType_UNO.hxx
+++ b/chart2/source/controller/inc/dlg_ChartType_UNO.hxx
@@ -40,7 +40,7 @@ private:
// OGenericUnoDialog overridables
virtual void implInitialize(const css::uno::Any& _rValue) override;
- virtual svt::OGenericUnoDialog::Dialog createDialog(const css::uno::Reference<css::awt::XWindow>& rParent) override;
+ virtual std::unique_ptr<weld::DialogController> createDialog(const css::uno::Reference<css::awt::XWindow>& rParent) override;
// XTypeProvider
virtual css::uno::Sequence<sal_Int8> SAL_CALL getImplementationId( ) override;
diff --git a/dbaccess/source/ui/inc/unosqlmessage.hxx b/dbaccess/source/ui/inc/unosqlmessage.hxx
index 3f9f960dd01a..b4d9fd279d83 100644
--- a/dbaccess/source/ui/inc/unosqlmessage.hxx
+++ b/dbaccess/source/ui/inc/unosqlmessage.hxx
@@ -70,7 +70,7 @@ private:
virtual sal_Bool SAL_CALL convertFastPropertyValue( css::uno::Any& _rConvertedValue, css::uno::Any& _rOldValue, sal_Int32 _nHandle, const css::uno::Any& _rValue) override;
// OGenericUnoDialog overridables
- virtual svt::OGenericUnoDialog::Dialog createDialog(const css::uno::Reference<css::awt::XWindow>& rParent) override;
+ virtual std::unique_ptr<weld::DialogController> createDialog(const css::uno::Reference<css::awt::XWindow>& rParent) override;
};
} // namespace dbaui
diff --git a/dbaccess/source/ui/uno/AdvancedSettingsDlg.cxx b/dbaccess/source/ui/uno/AdvancedSettingsDlg.cxx
index 7309fa7fe9d2..bd8e33d436dc 100644
--- a/dbaccess/source/ui/uno/AdvancedSettingsDlg.cxx
+++ b/dbaccess/source/ui/uno/AdvancedSettingsDlg.cxx
@@ -68,7 +68,7 @@ namespace dbaui
virtual ::cppu::IPropertyArrayHelper* createArrayHelper( ) const override;
protected:
// OGenericUnoDialog overridables
- virtual svt::OGenericUnoDialog::Dialog createDialog(const css::uno::Reference<css::awt::XWindow>& rParent) override;
+ virtual std::unique_ptr<weld::DialogController> createDialog(const css::uno::Reference<css::awt::XWindow>& rParent) override;
};
OAdvancedSettingsDialog::OAdvancedSettingsDialog(const Reference< XComponentContext >& _rxORB)
@@ -124,10 +124,10 @@ namespace dbaui
return new ::cppu::OPropertyArrayHelper(aProps);
}
- svt::OGenericUnoDialog::Dialog OAdvancedSettingsDialog::createDialog(const css::uno::Reference<css::awt::XWindow>& rParent)
+ std::unique_ptr<weld::DialogController> OAdvancedSettingsDialog::createDialog(const css::uno::Reference<css::awt::XWindow>& rParent)
{
- return svt::OGenericUnoDialog::Dialog(std::make_unique<AdvancedSettingsDialog>(Application::GetFrameWeld(rParent), m_pDatasourceItems.get(),
- m_aContext, m_aInitialSelection));
+ return std::make_unique<AdvancedSettingsDialog>(Application::GetFrameWeld(rParent), m_pDatasourceItems.get(),
+ m_aContext, m_aInitialSelection);
}
} // namespace dbaui
diff --git a/dbaccess/source/ui/uno/DBTypeWizDlg.cxx b/dbaccess/source/ui/uno/DBTypeWizDlg.cxx
index 683632a52cb0..963d3e136668 100644
--- a/dbaccess/source/ui/uno/DBTypeWizDlg.cxx
+++ b/dbaccess/source/ui/uno/DBTypeWizDlg.cxx
@@ -92,9 +92,9 @@ Reference<XPropertySetInfo> SAL_CALL ODBTypeWizDialog::getPropertySetInfo()
return new ::cppu::OPropertyArrayHelper(aProps);
}
-svt::OGenericUnoDialog::Dialog ODBTypeWizDialog::createDialog(const css::uno::Reference<css::awt::XWindow>& rParent)
+std::unique_ptr<weld::DialogController> ODBTypeWizDialog::createDialog(const css::uno::Reference<css::awt::XWindow>& rParent)
{
- return svt::OGenericUnoDialog::Dialog(std::make_unique<ODbTypeWizDialog>(Application::GetFrameWeld(rParent), m_pDatasourceItems.get(), m_aContext, m_aInitialSelection));
+ return std::make_unique<ODbTypeWizDialog>(Application::GetFrameWeld(rParent), m_pDatasourceItems.get(), m_aContext, m_aInitialSelection);
}
} // namespace dbaui
diff --git a/dbaccess/source/ui/uno/DBTypeWizDlg.hxx b/dbaccess/source/ui/uno/DBTypeWizDlg.hxx
index 85a1eabfbca0..1d134421f5b2 100644
--- a/dbaccess/source/ui/uno/DBTypeWizDlg.hxx
+++ b/dbaccess/source/ui/uno/DBTypeWizDlg.hxx
@@ -57,7 +57,7 @@ public:
virtual ::cppu::IPropertyArrayHelper* createArrayHelper( ) const override;
private:
// OGenericUnoDialog overridables
- virtual svt::OGenericUnoDialog::Dialog createDialog(const css::uno::Reference<css::awt::XWindow>& rParent) override;
+ virtual std::unique_ptr<weld::DialogController> createDialog(const css::uno::Reference<css::awt::XWindow>& rParent) override;
};
} // namespace dbaui
diff --git a/dbaccess/source/ui/uno/DBTypeWizDlgSetup.cxx b/dbaccess/source/ui/uno/DBTypeWizDlgSetup.cxx
index e372cbec082b..9bddf2cbbd42 100644
--- a/dbaccess/source/ui/uno/DBTypeWizDlgSetup.cxx
+++ b/dbaccess/source/ui/uno/DBTypeWizDlgSetup.cxx
@@ -107,16 +107,16 @@ Reference<XPropertySetInfo> SAL_CALL ODBTypeWizDialogSetup::getPropertySetInfo(
return new ::cppu::OPropertyArrayHelper(aProps);
}
-svt::OGenericUnoDialog::Dialog ODBTypeWizDialogSetup::createDialog(const css::uno::Reference<css::awt::XWindow>& rParent)
+std::unique_ptr<weld::DialogController> ODBTypeWizDialogSetup::createDialog(const css::uno::Reference<css::awt::XWindow>& rParent)
{
- return svt::OGenericUnoDialog::Dialog(std::make_unique<ODbTypeWizDialogSetup>(Application::GetFrameWeld(rParent), m_pDatasourceItems.get(), m_aContext, m_aInitialSelection));
+ return std::make_unique<ODbTypeWizDialogSetup>(Application::GetFrameWeld(rParent), m_pDatasourceItems.get(), m_aContext, m_aInitialSelection);
}
void ODBTypeWizDialogSetup::executedDialog(sal_Int16 nExecutionResult)
{
if (nExecutionResult == css::ui::dialogs::ExecutableDialogResults::OK)
{
- const ODbTypeWizDialogSetup* pDialog = static_cast<ODbTypeWizDialogSetup*>(m_aDialog.m_xWeldDialog.get());
+ const ODbTypeWizDialogSetup* pDialog = static_cast<ODbTypeWizDialogSetup*>(m_xDialog.get());
m_bOpenDatabase = pDialog->IsDatabaseDocumentToBeOpened();
m_bStartTableWizard = pDialog->IsTableWizardToBeStarted();
}
diff --git a/dbaccess/source/ui/uno/DBTypeWizDlgSetup.hxx b/dbaccess/source/ui/uno/DBTypeWizDlgSetup.hxx
index 80d185190f3c..65a25b5f09c1 100644
--- a/dbaccess/source/ui/uno/DBTypeWizDlgSetup.hxx
+++ b/dbaccess/source/ui/uno/DBTypeWizDlgSetup.hxx
@@ -59,7 +59,7 @@ public:
virtual ::cppu::IPropertyArrayHelper* createArrayHelper( ) const override;
private:
// OGenericUnoDialog overridables
- virtual svt::OGenericUnoDialog::Dialog createDialog(const css::uno::Reference<css::awt::XWindow>& rParent) override;
+ virtual std::unique_ptr<weld::DialogController> createDialog(const css::uno::Reference<css::awt::XWindow>& rParent) override;
virtual void executedDialog(sal_Int16 _nExecutionResult) override;
};
diff --git a/dbaccess/source/ui/uno/TableFilterDlg.cxx b/dbaccess/source/ui/uno/TableFilterDlg.cxx
index bb753ab79005..92fee688b89d 100644
--- a/dbaccess/source/ui/uno/TableFilterDlg.cxx
+++ b/dbaccess/source/ui/uno/TableFilterDlg.cxx
@@ -93,9 +93,9 @@ Reference<XPropertySetInfo> SAL_CALL OTableFilterDialog::getPropertySetInfo()
return new ::cppu::OPropertyArrayHelper(aProps);
}
-svt::OGenericUnoDialog::Dialog OTableFilterDialog::createDialog(const css::uno::Reference<css::awt::XWindow>& rParent)
+std::unique_ptr<weld::DialogController> OTableFilterDialog::createDialog(const css::uno::Reference<css::awt::XWindow>& rParent)
{
- return svt::OGenericUnoDialog::Dialog(std::make_unique<OTableSubscriptionDialog>(Application::GetFrameWeld(rParent), m_pDatasourceItems.get(), m_aContext, m_aInitialSelection));
+ return std::make_unique<OTableSubscriptionDialog>(Application::GetFrameWeld(rParent), m_pDatasourceItems.get(), m_aContext, m_aInitialSelection);
}
} // namespace dbaui
diff --git a/dbaccess/source/ui/uno/TableFilterDlg.hxx b/dbaccess/source/ui/uno/TableFilterDlg.hxx
index 88216ca0d7e7..6e80a1d5c16a 100644
--- a/dbaccess/source/ui/uno/TableFilterDlg.hxx
+++ b/dbaccess/source/ui/uno/TableFilterDlg.hxx
@@ -58,7 +58,7 @@ public:
virtual ::cppu::IPropertyArrayHelper* createArrayHelper( ) const override;
private:
// OGenericUnoDialog overridables
- virtual svt::OGenericUnoDialog::Dialog createDialog(const css::uno::Reference<css::awt::XWindow>& rParent) override;
+ virtual std::unique_ptr<weld::DialogController> createDialog(const css::uno::Reference<css::awt::XWindow>& rParent) override;
};
} // namespace dbaui
diff --git a/dbaccess/source/ui/uno/UserSettingsDlg.cxx b/dbaccess/source/ui/uno/UserSettingsDlg.cxx
index 1ed308c5d132..3bb09cad794b 100644
--- a/dbaccess/source/ui/uno/UserSettingsDlg.cxx
+++ b/dbaccess/source/ui/uno/UserSettingsDlg.cxx
@@ -93,9 +93,9 @@ Reference<XPropertySetInfo> SAL_CALL OUserSettingsDialog::getPropertySetInfo()
return new ::cppu::OPropertyArrayHelper(aProps);
}
-svt::OGenericUnoDialog::Dialog OUserSettingsDialog::createDialog(const css::uno::Reference<css::awt::XWindow>& rParent)
+std::unique_ptr<weld::DialogController> OUserSettingsDialog::createDialog(const css::uno::Reference<css::awt::XWindow>& rParent)
{
- return svt::OGenericUnoDialog::Dialog(std::make_unique<OUserAdminDlg>(Application::GetFrameWeld(rParent), m_pDatasourceItems.get(), m_aContext, m_aInitialSelection, m_xActiveConnection));
+ return std::make_unique<OUserAdminDlg>(Application::GetFrameWeld(rParent), m_pDatasourceItems.get(), m_aContext, m_aInitialSelection, m_xActiveConnection);
}
} // namespace dbaui
diff --git a/dbaccess/source/ui/uno/UserSettingsDlg.hxx b/dbaccess/source/ui/uno/UserSettingsDlg.hxx
index 316940611f4e..e70a57f60152 100644
--- a/dbaccess/source/ui/uno/UserSettingsDlg.hxx
+++ b/dbaccess/source/ui/uno/UserSettingsDlg.hxx
@@ -58,7 +58,7 @@ public:
virtual ::cppu::IPropertyArrayHelper* createArrayHelper( ) const override;
private:
// OGenericUnoDialog overridables
- virtual svt::OGenericUnoDialog::Dialog createDialog(const css::uno::Reference<css::awt::XWindow>& rParent) override;
+ virtual std::unique_ptr<weld::DialogController> createDialog(const css::uno::Reference<css::awt::XWindow>& rParent) override;
};
} // namespace dbaui
diff --git a/dbaccess/source/ui/uno/admindlg.cxx b/dbaccess/source/ui/uno/admindlg.cxx
index 92dc96ee9d5d..f5d9c97a7263 100644
--- a/dbaccess/source/ui/uno/admindlg.cxx
+++ b/dbaccess/source/ui/uno/admindlg.cxx
@@ -93,7 +93,7 @@ Reference<XPropertySetInfo> SAL_CALL ODataSourcePropertyDialog::getPropertySetI
return new ::cppu::OPropertyArrayHelper(aProps);
}
-svt::OGenericUnoDialog::Dialog ODataSourcePropertyDialog::createDialog(const css::uno::Reference<css::awt::XWindow>& rParent)
+std::unique_ptr<weld::DialogController> ODataSourcePropertyDialog::createDialog(const css::uno::Reference<css::awt::XWindow>& rParent)
{
std::unique_ptr<ODbAdminDialog> xDialog(new ODbAdminDialog(Application::GetFrameWeld(rParent), m_pDatasourceItems.get(), m_aContext));
@@ -101,7 +101,7 @@ svt::OGenericUnoDialog::Dialog ODataSourcePropertyDialog::createDialog(const css
if ( m_aInitialSelection.hasValue() )
xDialog->selectDataSource(m_aInitialSelection);
- return svt::OGenericUnoDialog::Dialog(std::move(xDialog));
+ return xDialog;
}
} // namespace dbaui
diff --git a/dbaccess/source/ui/uno/admindlg.hxx b/dbaccess/source/ui/uno/admindlg.hxx
index 4f367d298ba1..e4c817c3ca6f 100644
--- a/dbaccess/source/ui/uno/admindlg.hxx
+++ b/dbaccess/source/ui/uno/admindlg.hxx
@@ -57,7 +57,7 @@ public:
virtual ::cppu::IPropertyArrayHelper* createArrayHelper( ) const override;
private:
// OGenericUnoDialog overridables
- virtual svt::OGenericUnoDialog::Dialog createDialog(const css::uno::Reference<css::awt::XWindow>& rParent) override;
+ virtual std::unique_ptr<weld::DialogController> createDialog(const css::uno::Reference<css::awt::XWindow>& rParent) override;
};
} // namespace dbaui
diff --git a/dbaccess/source/ui/uno/composerdialogs.cxx b/dbaccess/source/ui/uno/composerdialogs.cxx
index 4b27f966bd8c..8d6e01b6a455 100644
--- a/dbaccess/source/ui/uno/composerdialogs.cxx
+++ b/dbaccess/source/ui/uno/composerdialogs.cxx
@@ -80,7 +80,7 @@ namespace dbaui
IMPLEMENT_PROPERTYCONTAINER_DEFAULTS( ComposerDialog )
- svt::OGenericUnoDialog::Dialog ComposerDialog::createDialog(const css::uno::Reference<css::awt::XWindow>& rParent)
+ std::unique_ptr<weld::DialogController> ComposerDialog::createDialog(const css::uno::Reference<css::awt::XWindow>& rParent)
{
// obtain all the objects needed for the dialog
Reference< XConnection > xConnection;
@@ -123,10 +123,10 @@ namespace dbaui
if ( !xConnection.is() || !xColumns.is() || !m_xComposer.is() )
{
// can't create the dialog if I have improper settings
- return svt::OGenericUnoDialog::Dialog();
+ return nullptr;
}
- return svt::OGenericUnoDialog::Dialog(createComposerDialog(Application::GetFrameWeld(rParent), xConnection, xColumns));
+ return createComposerDialog(Application::GetFrameWeld(rParent), xConnection, xColumns);
}
// RowsetFilterDialog
@@ -173,8 +173,8 @@ namespace dbaui
{
ComposerDialog::executedDialog( _nExecutionResult );
- if ( _nExecutionResult && m_aDialog )
- static_cast<DlgFilterCrit*>(m_aDialog.m_xWeldDialog.get())->BuildWherePart();
+ if ( _nExecutionResult && m_xDialog )
+ static_cast<DlgFilterCrit*>(m_xDialog.get())->BuildWherePart();
}
// RowsetOrderDialog
@@ -223,13 +223,13 @@ namespace dbaui
{
ComposerDialog::executedDialog( _nExecutionResult );
- if ( !m_aDialog )
+ if ( !m_xDialog )
return;
if ( _nExecutionResult )
- static_cast< DlgOrderCrit* >( m_aDialog.m_xWeldDialog.get() )->BuildOrderPart();
+ static_cast<DlgOrderCrit*>(m_xDialog.get())->BuildOrderPart();
else if ( m_xComposer.is() )
- m_xComposer->setOrder( static_cast< DlgOrderCrit* >( m_aDialog.m_xWeldDialog.get() )->GetOriginalOrder() );
+ m_xComposer->setOrder(static_cast<DlgOrderCrit*>(m_xDialog.get())->GetOriginalOrder());
}
} // namespace dbaui
diff --git a/dbaccess/source/ui/uno/composerdialogs.hxx b/dbaccess/source/ui/uno/composerdialogs.hxx
index 5ab489f46de2..a94b136199f9 100644
--- a/dbaccess/source/ui/uno/composerdialogs.hxx
+++ b/dbaccess/source/ui/uno/composerdialogs.hxx
@@ -68,7 +68,7 @@ namespace dbaui
private:
// OGenericUnoDialog overridables
- virtual svt::OGenericUnoDialog::Dialog createDialog(const css::uno::Reference<css::awt::XWindow>& rParent) override;
+ virtual std::unique_ptr<weld::DialogController> createDialog(const css::uno::Reference<css::awt::XWindow>& rParent) override;
};
// RowsetFilterDialog
diff --git a/dbaccess/source/ui/uno/copytablewizard.cxx b/dbaccess/source/ui/uno/copytablewizard.cxx
index 450634feb34f..a72758a39327 100644
--- a/dbaccess/source/ui/uno/copytablewizard.cxx
+++ b/dbaccess/source/ui/uno/copytablewizard.cxx
@@ -194,7 +194,7 @@ namespace dbaui
virtual ~CopyTableWizard() override;
// OGenericUnoDialog overridables
- virtual svt::OGenericUnoDialog::Dialog createDialog(const css::uno::Reference<css::awt::XWindow>& rParent) override;
+ virtual std::unique_ptr<weld::DialogController> createDialog(const css::uno::Reference<css::awt::XWindow>& rParent) override;
virtual void executedDialog( sal_Int16 _nExecutionResult ) override;
private:
@@ -548,7 +548,7 @@ void SAL_CALL CopyTableWizard::setTitle( const OUString& _rTitle )
OCopyTableWizard& CopyTableWizard::impl_getDialog_throw()
{
- OCopyTableWizard* pWizard = dynamic_cast<OCopyTableWizard*>(m_aDialog.m_xWeldDialog.get());
+ OCopyTableWizard* pWizard = dynamic_cast<OCopyTableWizard*>(m_xDialog.get());
if ( !pWizard )
throw DisposedException( OUString(), *this );
return *pWizard;
@@ -1506,7 +1506,7 @@ void SAL_CALL CopyTableWizard::initialize( const Sequence< Any >& _rArguments )
return new ::cppu::OPropertyArrayHelper( aProps );
}
-svt::OGenericUnoDialog::Dialog CopyTableWizard::createDialog(const css::uno::Reference<css::awt::XWindow>& rParent)
+std::unique_ptr<weld::DialogController> CopyTableWizard::createDialog(const css::uno::Reference<css::awt::XWindow>& rParent)
{
OSL_PRECOND( isInitialized(), "CopyTableWizard::createDialog: not initialized!" );
// this should have been prevented in ::execute already
@@ -1523,7 +1523,7 @@ svt::OGenericUnoDialog::Dialog CopyTableWizard::createDialog(const css::uno::Ref
impl_attributesToDialog_nothrow(*xWizard);
- return svt::OGenericUnoDialog::Dialog(std::move(xWizard));
+ return xWizard;
}
void CopyTableWizard::executedDialog( sal_Int16 _nExecutionResult )
diff --git a/dbaccess/source/ui/uno/textconnectionsettings_uno.cxx b/dbaccess/source/ui/uno/textconnectionsettings_uno.cxx
index 63bb97e8e466..ff9e8a3dee0a 100644
--- a/dbaccess/source/ui/uno/textconnectionsettings_uno.cxx
+++ b/dbaccess/source/ui/uno/textconnectionsettings_uno.cxx
@@ -104,7 +104,7 @@ namespace dbaui
protected:
// OGenericUnoDialog overridables
- virtual svt::OGenericUnoDialog::Dialog createDialog(const css::uno::Reference<css::awt::XWindow>& rParent) override;
+ virtual std::unique_ptr<weld::DialogController> createDialog(const css::uno::Reference<css::awt::XWindow>& rParent) override;
using OTextConnectionSettingsDialog_BASE::getFastPropertyValue;
};
@@ -201,9 +201,9 @@ namespace dbaui
return new ::cppu::OPropertyArrayHelper( aProps );
}
- svt::OGenericUnoDialog::Dialog OTextConnectionSettingsDialog::createDialog(const css::uno::Reference<css::awt::XWindow>& rParent)
+ std::unique_ptr<weld::DialogController> OTextConnectionSettingsDialog::createDialog(const css::uno::Reference<css::awt::XWindow>& rParent)
{
- return svt::OGenericUnoDialog::Dialog(std::make_unique<TextConnectionSettingsDialog>(Application::GetFrameWeld(rParent), *m_pDatasourceItems));
+ return std::make_unique<TextConnectionSettingsDialog>(Application::GetFrameWeld(rParent), *m_pDatasourceItems);
}
void SAL_CALL OTextConnectionSettingsDialog::setFastPropertyValue_NoBroadcast( sal_Int32 _nHandle, const Any& _rValue )
diff --git a/dbaccess/source/ui/uno/unoDirectSql.cxx b/dbaccess/source/ui/uno/unoDirectSql.cxx
index f3af4f40640e..07644a9c52cf 100644
--- a/dbaccess/source/ui/uno/unoDirectSql.cxx
+++ b/dbaccess/source/ui/uno/unoDirectSql.cxx
@@ -78,7 +78,7 @@ namespace dbaui
IMPLEMENT_PROPERTYCONTAINER_DEFAULTS( ODirectSQLDialog )
- svt::OGenericUnoDialog::Dialog ODirectSQLDialog::createDialog(const css::uno::Reference<css::awt::XWindow>& rParent)
+ std::unique_ptr<weld::DialogController> ODirectSQLDialog::createDialog(const css::uno::Reference<css::awt::XWindow>& rParent)
{
// obtain all the objects needed for the dialog
Reference< XConnection > xConnection = m_xActiveConnection;
@@ -99,10 +99,10 @@ namespace dbaui
if (!xConnection.is())
{
// can't create the dialog if I have improper settings
- return svt::OGenericUnoDialog::Dialog();
+ return nullptr;
}
- return svt::OGenericUnoDialog::Dialog(std::make_unique<DirectSQLDialog>(pParent, xConnection));
+ return std::make_unique<DirectSQLDialog>(pParent, xConnection);
}
void ODirectSQLDialog::implInitialize(const Any& _rValue)
diff --git a/dbaccess/source/ui/uno/unoDirectSql.hxx b/dbaccess/source/ui/uno/unoDirectSql.hxx
index f7a3a6ab0b17..7e34160c26da 100644
--- a/dbaccess/source/ui/uno/unoDirectSql.hxx
+++ b/dbaccess/source/ui/uno/unoDirectSql.hxx
@@ -61,7 +61,7 @@ namespace dbaui
protected:
// OGenericUnoDialog overridables
- virtual svt::OGenericUnoDialog::Dialog createDialog(const css::uno::Reference<css::awt::XWindow>& rParent) override;
+ virtual std::unique_ptr<weld::DialogController> createDialog(const css::uno::Reference<css::awt::XWindow>& rParent) override;
virtual void implInitialize(const css::uno::Any& _rValue) override;
};
diff --git a/dbaccess/source/ui/uno/unoadmin.cxx b/dbaccess/source/ui/uno/unoadmin.cxx
index b5039b6e542c..5885211d96d6 100644
--- a/dbaccess/source/ui/uno/unoadmin.cxx
+++ b/dbaccess/source/ui/uno/unoadmin.cxx
@@ -47,10 +47,10 @@ ODatabaseAdministrationDialog::ODatabaseAdministrationDialog(const Reference< XC
ODatabaseAdministrationDialog::~ODatabaseAdministrationDialog()
{
- if (m_aDialog)
+ if (m_xDialog)
{
::osl::MutexGuard aGuard(m_aMutex);
- if (m_aDialog)
+ if (m_xDialog)
{
destroyDialog();
ODbAdminDialog::destroyItemSet(m_pDatasourceItems, m_pItemPool, m_pItemPoolDefaults);
diff --git a/dbaccess/source/ui/uno/unosqlmessage.cxx b/dbaccess/source/ui/uno/unosqlmessage.cxx
index d9e02397bf78..cf8551c6a722 100644
--- a/dbaccess/source/ui/uno/unosqlmessage.cxx
+++ b/dbaccess/source/ui/uno/unosqlmessage.cxx
@@ -147,14 +147,14 @@ Reference<XPropertySetInfo> SAL_CALL OSQLMessageDialog::getPropertySetInfo()
return new ::cppu::OPropertyArrayHelper(aProps);
}
-svt::OGenericUnoDialog::Dialog OSQLMessageDialog::createDialog(const css::uno::Reference<css::awt::XWindow>& rParent)
+std::unique_ptr<weld::DialogController> OSQLMessageDialog::createDialog(const css::uno::Reference<css::awt::XWindow>& rParent)
{
weld::Window* pParent = Application::GetFrameWeld(rParent);
if ( m_aException.hasValue() )
- return svt::OGenericUnoDialog::Dialog(std::make_unique<OSQLMessageBox>(pParent, SQLExceptionInfo(m_aException), MessBoxStyle::Ok | MessBoxStyle::DefaultOk, m_sHelpURL));
+ return std::make_unique<OSQLMessageBox>(pParent, SQLExceptionInfo(m_aException), MessBoxStyle::Ok | MessBoxStyle::DefaultOk, m_sHelpURL);
OSL_FAIL("OSQLMessageDialog::createDialog : You should use the SQLException property to specify the error to display!");
- return svt::OGenericUnoDialog::Dialog(std::make_unique<OSQLMessageBox>(pParent, SQLException()));
+ return std::make_unique<OSQLMessageBox>(pParent, SQLException());
}
} // namespace dbaui
diff --git a/extensions/source/abpilot/unodialogabp.cxx b/extensions/source/abpilot/unodialogabp.cxx
index 90320dff9fd7..b8a958c51668 100644
--- a/extensions/source/abpilot/unodialogabp.cxx
+++ b/extensions/source/abpilot/unodialogabp.cxx
@@ -114,9 +114,9 @@ namespace abp
}
}
- svt::OGenericUnoDialog::Dialog OABSPilotUno::createDialog(const css::uno::Reference<css::awt::XWindow>& rParent)
+ std::unique_ptr<weld::DialogController> OABSPilotUno::createDialog(const css::uno::Reference<css::awt::XWindow>& rParent)
{
- return svt::OGenericUnoDialog::Dialog(std::make_unique<OAddressBookSourcePilot>(Application::GetFrameWeld(rParent), m_aContext));
+ return std::make_unique<OAddressBookSourcePilot>(Application::GetFrameWeld(rParent), m_aContext);
}
Any SAL_CALL OABSPilotUno::execute( const Sequence< NamedValue >& /*lArgs*/ )
@@ -138,7 +138,7 @@ namespace abp
{
if ( _nExecutionResult == RET_OK )
{
- const AddressSettings& aSettings = static_cast<OAddressBookSourcePilot*>(m_aDialog.m_xWeldDialog.get())->getSettings();
+ const AddressSettings& aSettings = static_cast<OAddressBookSourcePilot*>(m_xDialog.get())->getSettings();
m_sDataSourceName = aSettings.bRegisterDataSource ? aSettings.sRegisteredDataSourceName : aSettings.sDataSourceName;
}
}
diff --git a/extensions/source/abpilot/unodialogabp.hxx b/extensions/source/abpilot/unodialogabp.hxx
index f8f959585805..bdf6142c2992 100644
--- a/extensions/source/abpilot/unodialogabp.hxx
+++ b/extensions/source/abpilot/unodialogabp.hxx
@@ -71,7 +71,7 @@ namespace abp
using svt::OGenericUnoDialog::execute;
// OGenericUnoDialog overridables
- virtual svt::OGenericUnoDialog::Dialog createDialog(const css::uno::Reference<css::awt::XWindow>& rParent) override;
+ virtual std::unique_ptr<weld::DialogController> createDialog(const css::uno::Reference<css::awt::XWindow>& rParent) override;
virtual void executedDialog(sal_Int16 _nExecutionResult) override;
};
diff --git a/extensions/source/dbpilots/unoautopilot.hxx b/extensions/source/dbpilots/unoautopilot.hxx
index d0440f875dd7..4b69cd615ad9 100644
--- a/extensions/source/dbpilots/unoautopilot.hxx
+++ b/extensions/source/dbpilots/unoautopilot.hxx
@@ -104,9 +104,9 @@ namespace dbp
private:
// OGenericUnoDialog overridables
- virtual svt::OGenericUnoDialog::Dialog createDialog(const css::uno::Reference<css::awt::XWindow>& rParent) override
+ virtual std::unique_ptr<weld::DialogController> createDialog(const css::uno::Reference<css::awt::XWindow>& rParent) override
{
- return svt::OGenericUnoDialog::Dialog(std::make_unique<TYPE>(Application::GetFrameWeld(rParent), m_xObjectModel, m_aContext));
+ return std::make_unique<TYPE>(Application::GetFrameWeld(rParent), m_xObjectModel, m_aContext);
}
virtual void implInitialize(const css::uno::Any& _rValue) override
diff --git a/extensions/source/propctrlr/MasterDetailLinkDialog.cxx b/extensions/source/propctrlr/MasterDetailLinkDialog.cxx
index b69d6d540509..3b130c173cb4 100644
--- a/extensions/source/propctrlr/MasterDetailLinkDialog.cxx
+++ b/extensions/source/propctrlr/MasterDetailLinkDialog.cxx
@@ -100,11 +100,11 @@ namespace pcr
return new ::cppu::OPropertyArrayHelper(aProps);
}
- svt::OGenericUnoDialog::Dialog MasterDetailLinkDialog::createDialog(const css::uno::Reference<css::awt::XWindow>& rParent)
+ std::unique_ptr<weld::DialogController> MasterDetailLinkDialog::createDialog(const css::uno::Reference<css::awt::XWindow>& rParent)
{
- return svt::OGenericUnoDialog::Dialog(std::make_unique<FormLinkDialog>(Application::GetFrameWeld(rParent), m_xDetail,
- m_xMaster, m_aContext, m_sExplanation,
- m_sDetailLabel, m_sMasterLabel));
+ return std::make_unique<FormLinkDialog>(Application::GetFrameWeld(rParent), m_xDetail,
+ m_xMaster, m_aContext, m_sExplanation,
+ m_sDetailLabel, m_sMasterLabel);
}
void MasterDetailLinkDialog::implInitialize(const Any& _rValue)
diff --git a/extensions/source/propctrlr/MasterDetailLinkDialog.hxx b/extensions/source/propctrlr/MasterDetailLinkDialog.hxx
index cfc779459bdf..167fab31dc4d 100644
--- a/extensions/source/propctrlr/MasterDetailLinkDialog.hxx
+++ b/extensions/source/propctrlr/MasterDetailLinkDialog.hxx
@@ -60,7 +60,7 @@ namespace pcr
virtual ::cppu::IPropertyArrayHelper* createArrayHelper( ) const override;
// OGenericUnoDialog overridables
- virtual svt::OGenericUnoDialog::Dialog createDialog(const css::uno::Reference<css::awt::XWindow>& rParent) override;
+ virtual std::unique_ptr<weld::DialogController> createDialog(const css::uno::Reference<css::awt::XWindow>& rParent) override;
virtual void implInitialize(const css::uno::Any& _rValue) override;
css::uno::Reference< css::beans::XPropertySet> m_xDetail;
diff --git a/extensions/source/propctrlr/controlfontdialog.cxx b/extensions/source/propctrlr/controlfontdialog.cxx
index 5b34d7a76008..03d1db272e60 100644
--- a/extensions/source/propctrlr/controlfontdialog.cxx
+++ b/extensions/source/propctrlr/controlfontdialog.cxx
@@ -55,10 +55,10 @@ namespace pcr
OControlFontDialog::~OControlFontDialog()
{
- if (m_aDialog)
+ if (m_xDialog)
{
::osl::MutexGuard aGuard(m_aMutex);
- if (m_aDialog)
+ if (m_xDialog)
{
destroyDialog();
ControlCharacterDialog::destroyItemSet(m_pFontItems, m_pItemPool, m_pItemPoolDefaults);
@@ -140,7 +140,7 @@ namespace pcr
return new ::cppu::OPropertyArrayHelper(aProps);
}
- svt::OGenericUnoDialog::Dialog OControlFontDialog::createDialog(const css::uno::Reference<css::awt::XWindow>& rParent)
+ std::unique_ptr<weld::DialogController> OControlFontDialog::createDialog(const css::uno::Reference<css::awt::XWindow>& rParent)
{
ControlCharacterDialog::createItemSet(m_pFontItems, m_pItemPool, m_pItemPoolDefaults);
@@ -151,15 +151,15 @@ namespace pcr
// sets a new introspectee and re-executes us. In this case, the dialog returned here (upon the first
// execute) will be re-used upon the second execute, and thus it won't be initialized correctly.
- return svt::OGenericUnoDialog::Dialog(std::make_unique<ControlCharacterDialog>(Application::GetFrameWeld(rParent), *m_pFontItems));
+ return std::make_unique<ControlCharacterDialog>(Application::GetFrameWeld(rParent), *m_pFontItems);
}
void OControlFontDialog::executedDialog(sal_Int16 _nExecutionResult)
{
- OSL_ENSURE(m_aDialog, "OControlFontDialog::executedDialog: no dialog anymore?!!");
- if (m_aDialog && (RET_OK == _nExecutionResult) && m_xControlModel.is())
+ OSL_ENSURE(m_xDialog, "OControlFontDialog::executedDialog: no dialog anymore?!!");
+ if (m_xDialog && (RET_OK == _nExecutionResult) && m_xControlModel.is())
{
- const SfxItemSet* pOutput = static_cast<ControlCharacterDialog*>(m_aDialog.m_xWeldDialog.get())->GetOutputItemSet();
+ const SfxItemSet* pOutput = static_cast<ControlCharacterDialog*>(m_xDialog.get())->GetOutputItemSet();
if (pOutput)
ControlCharacterDialog::translateItemsToProperties( *pOutput, m_xControlModel );
}
diff --git a/extensions/source/propctrlr/controlfontdialog.hxx b/extensions/source/propctrlr/controlfontdialog.hxx
index ab57691ee798..89fc5920d4e5 100644
--- a/extensions/source/propctrlr/controlfontdialog.hxx
+++ b/extensions/source/propctrlr/controlfontdialog.hxx
@@ -81,7 +81,7 @@ namespace pcr
protected:
// OGenericUnoDialog overridables
- virtual svt::OGenericUnoDialog::Dialog createDialog(const css::uno::Reference<css::awt::XWindow>& rParent) override;
+ virtual std::unique_ptr<weld::DialogController> createDialog(const css::uno::Reference<css::awt::XWindow>& rParent) override;
virtual void executedDialog(sal_Int16 _nExecutionResult) override;
};
diff --git a/extensions/source/propctrlr/pcrunodialogs.cxx b/extensions/source/propctrlr/pcrunodialogs.cxx
index e072caa70b47..e54b9438a8fa 100644
--- a/extensions/source/propctrlr/pcrunodialogs.cxx
+++ b/extensions/source/propctrlr/pcrunodialogs.cxx
@@ -63,10 +63,10 @@ namespace pcr
OTabOrderDialog::~OTabOrderDialog()
{
- if (m_aDialog)
+ if (m_xDialog)
{
::osl::MutexGuard aGuard( m_aMutex );
- if (m_aDialog)
+ if (m_xDialog)
destroyDialog();
}
}
@@ -113,13 +113,11 @@ namespace pcr
return xInfo;
}
-
::cppu::IPropertyArrayHelper& OTabOrderDialog::getInfoHelper()
{
return *getArrayHelper();
}
-
::cppu::IPropertyArrayHelper* OTabOrderDialog::createArrayHelper( ) const
{
Sequence< Property > aProps;
@@ -127,9 +125,9 @@ namespace pcr
return new ::cppu::OPropertyArrayHelper( aProps );
}
- svt::OGenericUnoDialog::Dialog OTabOrderDialog::createDialog(const css::uno::Reference<css::awt::XWindow>& rParent)
+ std::unique_ptr<weld::DialogController> OTabOrderDialog::createDialog(const css::uno::Reference<css::awt::XWindow>& rParent)
{
- return svt::OGenericUnoDialog::Dialog(std::make_unique<TabOrderDialog>(Application::GetFrameWeld(rParent), m_xTabbingModel, m_xControlContext, m_aContext));
+ return std::make_unique<TabOrderDialog>(Application::GetFrameWeld(rParent), m_xTabbingModel, m_xControlContext, m_aContext);
}
void OTabOrderDialog::initialize( const Sequence< Any >& aArguments )
diff --git a/extensions/source/propctrlr/pcrunodialogs.hxx b/extensions/source/propctrlr/pcrunodialogs.hxx
index 0bf03f4ee7ad..99dbee245023 100644
--- a/extensions/source/propctrlr/pcrunodialogs.hxx
+++ b/extensions/source/propctrlr/pcrunodialogs.hxx
@@ -79,7 +79,7 @@ namespace pcr
protected:
// OGenericUnoDialog overridables
- virtual svt::OGenericUnoDialog::Dialog createDialog(const css::uno::Reference<css::awt::XWindow>& rParent) override;
+ virtual std::unique_ptr<weld::DialogController> createDialog(const css::uno::Reference<css::awt::XWindow>& rParent) override;
};
diff --git a/filter/source/flash/swfdialog.cxx b/filter/source/flash/swfdialog.cxx
index 56ff9ee5938b..c2ea828332ad 100644
--- a/filter/source/flash/swfdialog.cxx
+++ b/filter/source/flash/swfdialog.cxx
@@ -114,7 +114,7 @@ Sequence< OUString > SAL_CALL SWFDialog::getSupportedServiceNames()
return SWFDialog_getSupportedServiceNames();
}
-svt::OGenericUnoDialog::Dialog SWFDialog::createDialog(const css::uno::Reference<css::awt::XWindow>& rParent)
+std::unique_ptr<weld::DialogController> SWFDialog::createDialog(const css::uno::Reference<css::awt::XWindow>& rParent)
{
std::unique_ptr<weld::DialogController> xRet;
@@ -143,13 +143,13 @@ svt::OGenericUnoDialog::Dialog SWFDialog::createDialog(const css::uno::Reference
xRet.reset(new ImpSWFDialog(Application::GetFrameWeld(rParent), maFilterData));
}
- return svt::OGenericUnoDialog::Dialog(std::move(xRet));
+ return xRet;
}
void SWFDialog::executedDialog( sal_Int16 nExecutionResult )
{
- if (nExecutionResult && m_aDialog)
- maFilterData = static_cast<ImpSWFDialog*>(m_aDialog.m_xWeldDialog.get())->GetFilterData();
+ if (nExecutionResult && m_xDialog)
+ maFilterData = static_cast<ImpSWFDialog*>(m_xDialog.get())->GetFilterData();
destroyDialog();
}
diff --git a/filter/source/flash/swfdialog.hxx b/filter/source/flash/swfdialog.hxx
index c48a13198f2c..0ba61a6d7681 100644
--- a/filter/source/flash/swfdialog.hxx
+++ b/filter/source/flash/swfdialog.hxx
@@ -51,7 +51,7 @@ private:
virtual css::uno::Sequence< sal_Int8 > SAL_CALL getImplementationId() override;
virtual OUString SAL_CALL getImplementationName() override;
virtual css::uno::Sequence< OUString > SAL_CALL getSupportedServiceNames() override;
- virtual svt::OGenericUnoDialog::Dialog createDialog(const css::uno::Reference<css::awt::XWindow>& rParent) override;
+ virtual std::unique_ptr<weld::DialogController> createDialog(const css::uno::Reference<css::awt::XWindow>& rParent) override;
virtual void executedDialog( sal_Int16 nExecutionResult ) override;
virtual css::uno::Reference< css::beans::XPropertySetInfo> SAL_CALL getPropertySetInfo() override;
virtual ::cppu::IPropertyArrayHelper& SAL_CALL getInfoHelper() override;
diff --git a/filter/source/pdf/pdfdialog.cxx b/filter/source/pdf/pdfdialog.cxx
index da1333cb14bb..79dec365d437 100644
--- a/filter/source/pdf/pdfdialog.cxx
+++ b/filter/source/pdf/pdfdialog.cxx
@@ -83,17 +83,17 @@ Sequence< OUString > SAL_CALL PDFDialog::getSupportedServiceNames()
return PDFDialog_getSupportedServiceNames();
}
-svt::OGenericUnoDialog::Dialog PDFDialog::createDialog(const css::uno::Reference<css::awt::XWindow>& rParent)
+std::unique_ptr<weld::DialogController> PDFDialog::createDialog(const css::uno::Reference<css::awt::XWindow>& rParent)
{
if( mxSrcDoc.is() )
- return svt::OGenericUnoDialog::Dialog(std::make_unique<ImpPDFTabDialog>(Application::GetFrameWeld(rParent), maFilterData, mxSrcDoc));
- return svt::OGenericUnoDialog::Dialog();
+ return std::make_unique<ImpPDFTabDialog>(Application::GetFrameWeld(rParent), maFilterData, mxSrcDoc);
+ return nullptr;
}
void PDFDialog::executedDialog( sal_Int16 nExecutionResult )
{
- if (nExecutionResult && m_aDialog)
- maFilterData = static_cast<ImpPDFTabDialog*>(m_aDialog.m_xWeldDialog.get())->GetFilterData();
+ if (nExecutionResult && m_xDialog)
+ maFilterData = static_cast<ImpPDFTabDialog*>(m_xDialog.get())->GetFilterData();
destroyDialog();
}
diff --git a/filter/source/pdf/pdfdialog.hxx b/filter/source/pdf/pdfdialog.hxx
index 953555668b0f..2fa7ba76e257 100644
--- a/filter/source/pdf/pdfdialog.hxx
+++ b/filter/source/pdf/pdfdialog.hxx
@@ -44,7 +44,7 @@ private:
virtual Sequence< sal_Int8 > SAL_CALL getImplementationId() override;
virtual OUString SAL_CALL getImplementationName() override;
virtual Sequence< OUString > SAL_CALL getSupportedServiceNames() override;
- virtual svt::OGenericUnoDialog::Dialog createDialog(const css::uno::Reference<css::awt::XWindow>& rParent) override;
+ virtual std::unique_ptr<weld::DialogController> createDialog(const css::uno::Reference<css::awt::XWindow>& rParent) override;
virtual void executedDialog( sal_Int16 nExecutionResult ) override;
virtual Reference< XPropertySetInfo> SAL_CALL getPropertySetInfo() override;
virtual ::cppu::IPropertyArrayHelper& SAL_CALL getInfoHelper() override;
diff --git a/include/svtools/genericunodialog.hxx b/include/svtools/genericunodialog.hxx
index 4c8dc6ed768a..298d488d0d23 100644
--- a/include/svtools/genericunodialog.hxx
+++ b/include/svtools/genericunodialog.hxx
@@ -62,42 +62,8 @@ namespace svt
,public ::comphelper::OMutexAndBroadcastHelper
,public ::comphelper::OPropertyContainer
{
- public:
- struct Dialog
- {
- std::unique_ptr<weld::DialogController> m_xWeldDialog;
-
- Dialog()
- {
- }
-
- Dialog(std::unique_ptr<weld::DialogController> pWeldDialog)
- : m_xWeldDialog(std::move(pWeldDialog))
- {
- }
-
- explicit operator bool() const
- {
- return static_cast<bool>(m_xWeldDialog);
- }
-
- void set_title(const OUString& rTitle)
- {
- m_xWeldDialog->set_title(rTitle);
- }
-
- OString get_help_id() const
- {
- return m_xWeldDialog->get_help_id();
- }
-
- void set_help_id(const OString& rHelpId)
- {
- return m_xWeldDialog->set_help_id(rHelpId);
- }
- };
protected:
- OGenericUnoDialog::Dialog m_aDialog; /// the dialog to execute
+ std::unique_ptr<weld::DialogController> m_xDialog; /// the dialog to execute
bool m_bExecuting : 1; /// we're currently executing the dialog
bool m_bTitleAmbiguous : 1; /// m_sTitle has not been set yet
bool m_bInitialized : 1; /// has "initialize" been called?
@@ -143,7 +109,7 @@ namespace svt
but the application-wide solar mutex is (to guard the not thread-safe ctor of the dialog).
@param pParent the parent window for the new dialog
*/
- virtual OGenericUnoDialog::Dialog createDialog(const css::uno::Reference<css::awt::XWindow>& rParent) = 0;
+ virtual std::unique_ptr<weld::DialogController> createDialog(const css::uno::Reference<css::awt::XWindow>& rParent) = 0;
/// called to destroy the dialog used. deletes m_pDialog and resets it to NULL
void destroyDialog();
diff --git a/svtools/source/uno/addrtempuno.cxx b/svtools/source/uno/addrtempuno.cxx
index 777883ae0615..7af43f88e95c 100644
--- a/svtools/source/uno/addrtempuno.cxx
+++ b/svtools/source/uno/addrtempuno.cxx
@@ -71,7 +71,7 @@ namespace {
protected:
// OGenericUnoDialog overridables
- virtual svt::OGenericUnoDialog::Dialog createDialog(const css::uno::Reference<css::awt::XWindow>& rParent) override;
+ virtual std::unique_ptr<weld::DialogController> createDialog(const css::uno::Reference<css::awt::XWindow>& rParent) override;
virtual void implInitialize(const css::uno::Any& _rValue) override;
@@ -128,8 +128,8 @@ namespace {
{
OGenericUnoDialog::executedDialog(_nExecutionResult);
- if ( _nExecutionResult && m_aDialog )
- static_cast<AddressBookSourceDialog*>(m_aDialog.m_xWeldDialog.get())->getFieldMapping(m_aAliases);
+ if ( _nExecutionResult && m_xDialog )
+ static_cast<AddressBookSourceDialog*>(m_xDialog.get())->getFieldMapping(m_aAliases);
}
void SAL_CALL OAddressBookSourceDialogUno::initialize(const Sequence< Any >& rArguments)
@@ -194,13 +194,12 @@ namespace {
OGenericUnoDialog::implInitialize( _rValue );
}
- svt::OGenericUnoDialog::Dialog OAddressBookSourceDialogUno::createDialog(const css::uno::Reference<css::awt::XWindow>& rParent)
+ std::unique_ptr<weld::DialogController> OAddressBookSourceDialogUno::createDialog(const css::uno::Reference<css::awt::XWindow>& rParent)
{
weld::Window* pParent = Application::GetFrameWeld(rParent);
if ( m_xDataSource.is() && !m_sTable.isEmpty() )
- return svt::OGenericUnoDialog::Dialog(std::make_unique<AddressBookSourceDialog>(pParent, m_aContext, m_xDataSource, m_sDataSourceName, m_sTable, m_aAliases));
- else
- return svt::OGenericUnoDialog::Dialog(std::make_unique<AddressBookSourceDialog>(pParent, m_aContext));
+ return std::make_unique<AddressBookSourceDialog>(pParent, m_aContext, m_xDataSource, m_sDataSourceName, m_sTable, m_aAliases);
+ return std::make_unique<AddressBookSourceDialog>(pParent, m_aContext);
}
}
diff --git a/svtools/source/uno/genericunodialog.cxx b/svtools/source/uno/genericunodialog.cxx
index d99c2593531f..e4e61c2d52cd 100644
--- a/svtools/source/uno/genericunodialog.cxx
+++ b/svtools/source/uno/genericunodialog.cxx
@@ -58,11 +58,11 @@ OGenericUnoDialog::OGenericUnoDialog(const Reference< XComponentContext >& _rxCo
OGenericUnoDialog::~OGenericUnoDialog()
{
- if (m_aDialog)
+ if (m_xDialog)
{
SolarMutexGuard aSolarGuard;
::osl::MutexGuard aGuard( m_aMutex );
- if (m_aDialog)
+ if (m_xDialog)
destroyDialog();
}
}
@@ -108,8 +108,8 @@ void OGenericUnoDialog::setFastPropertyValue_NoBroadcast( sal_Int32 nHandle, con
// from now on m_sTitle is valid
m_bTitleAmbiguous = false;
- if (m_aDialog)
- m_aDialog.set_title(m_sTitle);
+ if (m_xDialog)
+ m_xDialog->set_title(m_sTitle);
}
}
@@ -157,7 +157,7 @@ void SAL_CALL OGenericUnoDialog::setTitle( const OUString& _rTitle )
bool OGenericUnoDialog::impl_ensureDialog_lck()
{
- if (m_aDialog)
+ if (m_xDialog)
return true;
// get the parameters for the dialog from the current settings
@@ -165,16 +165,16 @@ bool OGenericUnoDialog::impl_ensureDialog_lck()
// the title
OUString sTitle = m_sTitle;
- OGenericUnoDialog::Dialog aDialog(createDialog(m_xParent));
- OSL_ENSURE(aDialog, "OGenericUnoDialog::impl_ensureDialog_lck: createDialog returned nonsense!");
- if (!aDialog)
+ auto xDialog(createDialog(m_xParent));
+ OSL_ENSURE(xDialog, "OGenericUnoDialog::impl_ensureDialog_lck: createDialog returned nonsense!");
+ if (!xDialog)
return false;
// do some initialisations
if (!m_bTitleAmbiguous)
- aDialog.set_title(sTitle);
+ xDialog->set_title(sTitle);
- m_aDialog = std::move(aDialog);
+ m_xDialog = std::move(xDialog);
return true;
}
@@ -202,8 +202,8 @@ sal_Int16 SAL_CALL OGenericUnoDialog::execute()
// start execution
sal_Int16 nReturn(0);
- if (m_aDialog.m_xWeldDialog)
- nReturn = m_aDialog.m_xWeldDialog->run();
+ if (m_xDialog)
+ nReturn = m_xDialog->run();
{
::osl::MutexGuard aGuard(m_aMutex);
@@ -254,7 +254,7 @@ void SAL_CALL OGenericUnoDialog::initialize( const Sequence< Any >& aArguments )
void OGenericUnoDialog::destroyDialog()
{
SolarMutexGuard aSolarGuard;
- m_aDialog.m_xWeldDialog.reset();
+ m_xDialog.reset();
}
} // namespace svt
diff --git a/svtools/source/uno/wizard/unowizard.cxx b/svtools/source/uno/wizard/unowizard.cxx
index 856d0ba3dafc..decbada6b887 100644
--- a/svtools/source/uno/wizard/unowizard.cxx
+++ b/svtools/source/uno/wizard/unowizard.cxx
@@ -130,7 +130,7 @@ namespace {
virtual ~Wizard() override;
protected:
- virtual OGenericUnoDialog::Dialog createDialog(const css::uno::Reference<css::awt::XWindow>& rParent) override;
+ virtual std::unique_ptr<weld::DialogController> createDialog(const css::uno::Reference<css::awt::XWindow>& rParent) override;
private:
css::uno::Sequence< css::uno::Sequence< sal_Int16 > > m_aWizardSteps;
@@ -157,12 +157,12 @@ namespace {
Wizard::~Wizard()
{
- if (m_aDialog)
+ if (m_xDialog)
{
::osl::MutexGuard aGuard( m_aMutex );
- if (m_aDialog)
+ if (m_xDialog)
{
- m_sHelpURL = lcl_getHelpURL(m_aDialog.get_help_id());
+ m_sHelpURL = lcl_getHelpURL(m_xDialog->get_help_id());
destroyDialog();
}
}
@@ -245,12 +245,12 @@ namespace {
return OUStringToOString( _rHelpURL, RTL_TEXTENCODING_UTF8 );
}
- svt::OGenericUnoDialog::Dialog Wizard::createDialog(const css::uno::Reference<css::awt::XWindow>& rParent)
+ std::unique_ptr<weld::DialogController> Wizard::createDialog(const css::uno::Reference<css::awt::XWindow>& rParent)
{
auto xDialog = std::make_unique<WizardShell>(Application::GetFrameWeld(rParent), m_xController, m_aWizardSteps);
xDialog->set_help_id(lcl_getHelpId(m_sHelpURL));
xDialog->setTitleBase( m_sTitle );
- return OGenericUnoDialog::Dialog(std::move(xDialog));
+ return xDialog;
}
OUString SAL_CALL Wizard::getImplementationName()
@@ -286,10 +286,10 @@ namespace {
SolarMutexGuard aSolarGuard;
::osl::MutexGuard aGuard( m_aMutex );
- if (!m_aDialog)
+ if (!m_xDialog)
return m_sHelpURL;
- return lcl_getHelpURL(m_aDialog.get_help_id());
+ return lcl_getHelpURL(m_xDialog->get_help_id());
}
void SAL_CALL Wizard::setHelpURL( const OUString& i_HelpURL )
@@ -297,10 +297,10 @@ namespace {
SolarMutexGuard aSolarGuard;
::osl::MutexGuard aGuard( m_aMutex );
- if (!m_aDialog)
+ if (!m_xDialog)
m_sHelpURL = i_HelpURL;
else
- m_aDialog.set_help_id(lcl_getHelpId(i_HelpURL));
+ m_xDialog->set_help_id(lcl_getHelpId(i_HelpURL));
}
Reference< XWindow > SAL_CALL Wizard::getDialogWindow()
@@ -308,8 +308,8 @@ namespace {
SolarMutexGuard aSolarGuard;
::osl::MutexGuard aGuard( m_aMutex );
- ENSURE_OR_RETURN( m_aDialog.m_xWeldDialog, "Wizard::getDialogWindow: illegal call (execution did not start, yet)!", nullptr );
- return m_aDialog.m_xWeldDialog->getDialog()->GetXWindow();
+ ENSURE_OR_RETURN( m_xDialog, "Wizard::getDialogWindow: illegal call (execution did not start, yet)!", nullptr );
+ return m_xDialog->getDialog()->GetXWindow();
}
void SAL_CALL Wizard::enableButton( ::sal_Int16 i_WizardButton, sal_Bool i_Enable )
@@ -317,7 +317,7 @@ namespace {
SolarMutexGuard aSolarGuard;
::osl::MutexGuard aGuard( m_aMutex );
- WizardShell* pWizardImpl = dynamic_cast< WizardShell* >( m_aDialog.m_xWeldDialog.get() );
+ WizardShell* pWizardImpl = dynamic_cast<WizardShell*>(m_xDialog.get());
ENSURE_OR_RETURN_VOID( pWizardImpl, "Wizard::enableButtons: invalid dialog implementation!" );
pWizardImpl->enableButtons( lcl_convertWizardButtonToWZB( i_WizardButton ), i_Enable );
@@ -328,7 +328,7 @@ namespace {
SolarMutexGuard aSolarGuard;
::osl::MutexGuard aGuard( m_aMutex );
- WizardShell* pWizardImpl = dynamic_cast< WizardShell* >( m_aDialog.m_xWeldDialog.get() );
+ WizardShell* pWizardImpl = dynamic_cast<WizardShell*>(m_xDialog.get());
ENSURE_OR_RETURN_VOID( pWizardImpl, "Wizard::setDefaultButton: invalid dialog implementation!" );
pWizardImpl->defaultButton( lcl_convertWizardButtonToWZB( i_WizardButton ) );
@@ -339,7 +339,7 @@ namespace {
SolarMutexGuard aSolarGuard;
::osl::MutexGuard aGuard( m_aMutex );
- WizardShell* pWizardImpl = dynamic_cast< WizardShell* >( m_aDialog.m_xWeldDialog.get() );
+ WizardShell* pWizardImpl = dynamic_cast<WizardShell*>(m_xDialog.get());
ENSURE_OR_RETURN_FALSE( pWizardImpl, "Wizard::travelNext: invalid dialog implementation!" );
return pWizardImpl->travelNext();
@@ -350,7 +350,7 @@ namespace {
SolarMutexGuard aSolarGuard;
::osl::MutexGuard aGuard( m_aMutex );
- WizardShell* pWizardImpl = dynamic_cast< WizardShell* >( m_aDialog.m_xWeldDialog.get() );
+ WizardShell* pWizardImpl = dynamic_cast<WizardShell*>(m_xDialog.get());
ENSURE_OR_RETURN_FALSE( pWizardImpl, "Wizard::travelPrevious: invalid dialog implementation!" );
return pWizardImpl->travelPrevious();
@@ -361,7 +361,7 @@ namespace {
SolarMutexGuard aSolarGuard;
::osl::MutexGuard aGuard( m_aMutex );
- WizardShell* pWizardImpl = dynamic_cast< WizardShell* >( m_aDialog.m_xWeldDialog.get() );
+ WizardShell* pWizardImpl = dynamic_cast<WizardShell*>(m_xDialog.get());
ENSURE_OR_RETURN_VOID( pWizardImpl, "Wizard::enablePage: invalid dialog implementation!" );
if ( !pWizardImpl->knowsPage( i_PageID ) )
@@ -378,7 +378,7 @@ namespace {
SolarMutexGuard aSolarGuard;
::osl::MutexGuard aGuard( m_aMutex );
- WizardShell* pWizardImpl = dynamic_cast< WizardShell* >( m_aDialog.m_xWeldDialog.get() );
+ WizardShell* pWizardImpl = dynamic_cast<WizardShell*>(m_xDialog.get());
ENSURE_OR_RETURN_VOID( pWizardImpl, "Wizard::updateTravelUI: invalid dialog implementation!" );
pWizardImpl->updateTravelUI();
@@ -389,7 +389,7 @@ namespace {
SolarMutexGuard aSolarGuard;
::osl::MutexGuard aGuard( m_aMutex );
- WizardShell* pWizardImpl = dynamic_cast< WizardShell* >( m_aDialog.m_xWeldDialog.get() );
+ WizardShell* pWizardImpl = dynamic_cast<WizardShell*>(m_xDialog.get());
ENSURE_OR_RETURN_FALSE( pWizardImpl, "Wizard::advanceTo: invalid dialog implementation!" );
return pWizardImpl->advanceTo( i_PageId );
@@ -400,7 +400,7 @@ namespace {
SolarMutexGuard aSolarGuard;
::osl::MutexGuard aGuard( m_aMutex );
- WizardShell* pWizardImpl = dynamic_cast< WizardShell* >( m_aDialog.m_xWeldDialog.get() );
+ WizardShell* pWizardImpl = dynamic_cast<WizardShell*>(m_xDialog.get());
ENSURE_OR_RETURN_FALSE( pWizardImpl, "Wizard::goBackTo: invalid dialog implementation!" );
return pWizardImpl->goBackTo( i_PageId );
@@ -411,7 +411,7 @@ namespace {
SolarMutexGuard aSolarGuard;
::osl::MutexGuard aGuard( m_aMutex );
- WizardShell* pWizardImpl = dynamic_cast< WizardShell* >( m_aDialog.m_xWeldDialog.get() );
+ WizardShell* pWizardImpl = dynamic_cast<WizardShell*>(m_xDialog.get());
ENSURE_OR_RETURN( pWizardImpl, "Wizard::getCurrentPage: invalid dialog implementation!", Reference< XWizardPage >() );
return pWizardImpl->getCurrentWizardPage();
@@ -425,7 +425,7 @@ namespace {
if ( ( i_PathIndex < 0 ) || ( i_PathIndex >= m_aWizardSteps.getLength() ) )
throw NoSuchElementException( OUString(), *this );
- WizardShell* pWizardImpl = dynamic_cast< WizardShell* >( m_aDialog.m_xWeldDialog.get() );
+ WizardShell* pWizardImpl = dynamic_cast<WizardShell*>(m_xDialog.get());
ENSURE_OR_RETURN_VOID( pWizardImpl, "Wizard::activatePath: invalid dialog implementation!" );
pWizardImpl->activatePath( i_PathIndex, i_Final );
diff --git a/svx/source/form/xfm_addcondition.cxx b/svx/source/form/xfm_addcondition.cxx
index fecbc2d99c27..398623cf9460 100644
--- a/svx/source/form/xfm_addcondition.cxx
+++ b/svx/source/form/xfm_addcondition.cxx
@@ -139,19 +139,19 @@ namespace svxform
return new ::cppu::OPropertyArrayHelper( aProperties );
}
- svt::OGenericUnoDialog::Dialog OAddConditionDialog::createDialog(const css::uno::Reference<css::awt::XWindow>& rParent)
+ std::unique_ptr<weld::DialogController> OAddConditionDialog::createDialog(const css::uno::Reference<css::awt::XWindow>& rParent)
{
if ( !m_xBinding.is() || m_sFacetName.isEmpty() )
throw RuntimeException( OUString(), *this );
- return svt::OGenericUnoDialog::Dialog(std::make_unique<AddConditionDialog>(Application::GetFrameWeld(rParent), m_sFacetName, m_xBinding));
+ return std::make_unique<AddConditionDialog>(Application::GetFrameWeld(rParent), m_sFacetName, m_xBinding);
}
void OAddConditionDialog::executedDialog( sal_Int16 _nExecutionResult )
{
OAddConditionDialogBase::executedDialog( _nExecutionResult );
if ( _nExecutionResult == RET_OK )
- m_sConditionValue = static_cast< AddConditionDialog* >( m_aDialog.m_xWeldDialog.get() )->GetCondition();
+ m_sConditionValue = static_cast<AddConditionDialog*>(m_xDialog.get())->GetCondition();
}
}
diff --git a/svx/source/inc/xfm_addcondition.hxx b/svx/source/inc/xfm_addcondition.hxx
index 34d6a06b9ad4..10d4674cbf57 100644
--- a/svx/source/inc/xfm_addcondition.hxx
+++ b/svx/source/inc/xfm_addcondition.hxx
@@ -56,7 +56,7 @@ namespace svxform
virtual ::cppu::IPropertyArrayHelper* createArrayHelper( ) const override;
// OGenericUnoDialog overridables
- virtual svt::OGenericUnoDialog::Dialog createDialog(const css::uno::Reference<css::awt::XWindow>& rParent) override;
+ virtual std::unique_ptr<weld::DialogController> createDialog(const css::uno::Reference<css::awt::XWindow>& rParent) override;
virtual void executedDialog(sal_Int16 _nExecutionResult) override;
css::uno::Reference< css::beans::XPropertySet >