diff options
author | Caolán McNamara <caolanm@redhat.com> | 2018-03-16 20:35:23 +0000 |
---|---|---|
committer | Caolán McNamara <caolanm@redhat.com> | 2018-03-18 13:43:34 +0100 |
commit | 2fb266bb77722cd45af7346e99a8f214c3f8b198 (patch) | |
tree | 00901e9e800809ea30ab378be622446bb7804e46 /sfx2 | |
parent | 6709db941ff3257226f48212d2c36ee1b0d68200 (diff) |
unify the message dialogs with extra widgets cases
Change-Id: I9ad3573b15d24c3d1737b9f450792952ae20a31b
Reviewed-on: https://gerrit.libreoffice.org/51476
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 'sfx2')
-rw-r--r-- | sfx2/source/dialog/alienwarn.cxx | 11 | ||||
-rw-r--r-- | sfx2/source/inc/alienwarn.hxx | 3 |
2 files changed, 1 insertions, 13 deletions
diff --git a/sfx2/source/dialog/alienwarn.cxx b/sfx2/source/dialog/alienwarn.cxx index d9eeed1bd956..d5b45ba091a6 100644 --- a/sfx2/source/dialog/alienwarn.cxx +++ b/sfx2/source/dialog/alienwarn.cxx @@ -27,18 +27,11 @@ SfxAlienWarningDialog::SfxAlienWarningDialog(weld::Window* pParent, const OUString& _rFormatName, const OUString& _rDefaultExtension, bool rDefaultIsAlien) - : MessageDialogController(pParent, "sfx/ui/alienwarndialog.ui", "AlienWarnDialog") + : MessageDialogController(pParent, "sfx/ui/alienwarndialog.ui", "AlienWarnDialog", "ask") , m_xKeepCurrentBtn(m_xBuilder->weld_button("save")) , m_xUseDefaultFormatBtn(m_xBuilder->weld_button("cancel")) , m_xWarningOnBox(m_xBuilder->weld_check_button("ask")) - , m_xOrigParent(m_xWarningOnBox->weld_parent()) - , m_xContentArea(m_xDialog->weld_message_area()) { - //fdo#75121, a bit tricky because the widgets we want to align with - //don't actually exist in the ui description, they're implied - m_xOrigParent->remove(m_xWarningOnBox.get()); - m_xContentArea->add(m_xWarningOnBox.get()); - OUString aExtension = "ODF"; // replace formatname (text) @@ -70,8 +63,6 @@ SfxAlienWarningDialog::SfxAlienWarningDialog(weld::Window* pParent, const OUStri SfxAlienWarningDialog::~SfxAlienWarningDialog() { - m_xContentArea->remove(m_xWarningOnBox.get()); - m_xOrigParent->add(m_xWarningOnBox.get()); // save value of "warning off" checkbox, if necessary SvtSaveOptions aSaveOpt; bool bChecked = m_xWarningOnBox->get_active(); diff --git a/sfx2/source/inc/alienwarn.hxx b/sfx2/source/inc/alienwarn.hxx index 5b93430882d8..eeda0fedfe1d 100644 --- a/sfx2/source/inc/alienwarn.hxx +++ b/sfx2/source/inc/alienwarn.hxx @@ -28,9 +28,6 @@ private: std::unique_ptr<weld::Button> m_xUseDefaultFormatBtn; std::unique_ptr<weld::CheckButton> m_xWarningOnBox; - std::unique_ptr<weld::Container> m_xOrigParent; - std::unique_ptr<weld::Container> m_xContentArea; - public: SfxAlienWarningDialog(weld::Window* pParent, const OUString& _rFormatName, const OUString& _rDefaultExtension, bool rDefaultIsAlien); |