summaryrefslogtreecommitdiff
path: root/svx
diff options
context:
space:
mode:
authorCaolán McNamara <caolanm@redhat.com>2018-03-08 09:49:36 +0000
committerCaolán McNamara <caolanm@redhat.com>2018-03-09 13:47:52 +0100
commit48bca65f1cf381cba7cb7a4c3916155a1bca0955 (patch)
treedf461652450b3e095e37a3290cbe54ab20cedfae /svx
parentc468b6910bf77e332647725da70e3cb248a9de0e (diff)
inherit welded dialogs from a common ancestor
Change-Id: Ifa6c871a134cf89bfba71b1049a115cf7c953c42 Reviewed-on: https://gerrit.libreoffice.org/50936 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Caolán McNamara <caolanm@redhat.com> Tested-by: Caolán McNamara <caolanm@redhat.com>
Diffstat (limited to 'svx')
-rw-r--r--svx/source/dialog/linkwarn.cxx3
-rw-r--r--svx/source/form/datanavi.cxx4
-rw-r--r--svx/source/inc/datanavi.hxx6
3 files changed, 4 insertions, 9 deletions
diff --git a/svx/source/dialog/linkwarn.cxx b/svx/source/dialog/linkwarn.cxx
index 23a4f0d2102f..2dcf5be18747 100644
--- a/svx/source/dialog/linkwarn.cxx
+++ b/svx/source/dialog/linkwarn.cxx
@@ -23,8 +23,7 @@
#include <svtools/miscopt.hxx>
SvxLinkWarningDialog::SvxLinkWarningDialog(weld::Widget* pParent, const OUString& _rFileName)
- : m_xBuilder(Application::CreateBuilder(pParent, "svx/ui/linkwarndialog.ui"))
- , m_xDialog(m_xBuilder->weld_message_dialog("LinkWarnDialog"))
+ : MessageDialogController(pParent, "svx/ui/linkwarndialog.ui", "LinkWarnDialog")
, m_xWarningOnBox(m_xBuilder->weld_check_button("ask"))
{
// replace filename
diff --git a/svx/source/form/datanavi.cxx b/svx/source/form/datanavi.cxx
index 9f0bf7f064d2..7d686263a2ef 100644
--- a/svx/source/form/datanavi.cxx
+++ b/svx/source/form/datanavi.cxx
@@ -3402,8 +3402,8 @@ namespace svxform
}
LinkedInstanceWarningBox::LinkedInstanceWarningBox(weld::Widget* pParent)
- : m_xBuilder(Application::CreateBuilder(pParent, "svx/ui/formlinkwarndialog.ui"))
- , m_xDialog(m_xBuilder->weld_message_dialog("FormLinkWarnDialog"))
+ : MessageDialogController(pParent, "svx/ui/formlinkwarndialog.ui",
+ "FormLinkWarnDialog")
{
}
diff --git a/svx/source/inc/datanavi.hxx b/svx/source/inc/datanavi.hxx
index c2daff365856..323b7bad3029 100644
--- a/svx/source/inc/datanavi.hxx
+++ b/svx/source/inc/datanavi.hxx
@@ -633,14 +633,10 @@ namespace svxform
};
- class LinkedInstanceWarningBox
+ class LinkedInstanceWarningBox : public weld::MessageDialogController
{
- private:
- std::unique_ptr<weld::Builder> m_xBuilder;
- std::unique_ptr<weld::MessageDialog> m_xDialog;
public:
LinkedInstanceWarningBox(weld::Widget* pParent);
- short run() { return m_xDialog->run(); }
};
}