summaryrefslogtreecommitdiff
path: root/filter/source/pdf/pdfdialog.cxx
diff options
context:
space:
mode:
Diffstat (limited to 'filter/source/pdf/pdfdialog.cxx')
-rw-r--r--filter/source/pdf/pdfdialog.cxx24
1 files changed, 24 insertions, 0 deletions
diff --git a/filter/source/pdf/pdfdialog.cxx b/filter/source/pdf/pdfdialog.cxx
index 7c3e5dda1956..c036fc747b2a 100644
--- a/filter/source/pdf/pdfdialog.cxx
+++ b/filter/source/pdf/pdfdialog.cxx
@@ -62,6 +62,13 @@ std::unique_ptr<weld::DialogController> PDFDialog::createDialog(const css::uno::
return nullptr;
}
+std::shared_ptr<SfxTabDialogController> PDFDialog::createAsyncDialog(const css::uno::Reference<css::awt::XWindow>& rParent)
+{
+ if( mxSrcDoc.is() )
+ return std::make_shared<ImpPDFTabDialog>(Application::GetFrameWeld(rParent), maFilterData, mxSrcDoc);
+ return nullptr;
+}
+
void PDFDialog::executedDialog( sal_Int16 nExecutionResult )
{
if (nExecutionResult && m_xDialog)
@@ -69,6 +76,23 @@ void PDFDialog::executedDialog( sal_Int16 nExecutionResult )
destroyDialog();
}
+void PDFDialog::runAsync(const css::uno::Reference< css::ui::dialogs::XDialogClosedListener >& xListener)
+{
+ SfxTabDialogController::runAsync(m_xAsyncDialog, [this, xListener](sal_Int32 nResponse) {
+ executedAsyncDialog( m_xAsyncDialog, nResponse );
+ css::ui::dialogs::DialogClosedEvent aEvent;
+ aEvent.DialogResult = nResponse;
+ xListener->dialogClosed( aEvent );
+ destroyAsyncDialog();
+ });
+}
+
+void PDFDialog::executedAsyncDialog( std::shared_ptr<SfxTabDialogController> xAsyncDialog, sal_Int32 nExecutionResult )
+{
+ if (nExecutionResult && xAsyncDialog)
+ maFilterData = static_cast<ImpPDFTabDialog*>(xAsyncDialog.get())->GetFilterData();
+}
+
Reference< XPropertySetInfo > SAL_CALL PDFDialog::getPropertySetInfo()
{
Reference< XPropertySetInfo > xInfo( createPropertySetInfo( getInfoHelper() ) );