diff options
author | Caolán McNamara <caolanm@redhat.com> | 2018-02-26 13:28:48 +0000 |
---|---|---|
committer | Caolán McNamara <caolanm@redhat.com> | 2018-02-27 09:52:32 +0000 |
commit | 0fad8d308122a862aa49dece498d56a418df2afe (patch) | |
tree | e67e7df1f9d315648535f436b424c9941dea589e /sfx2/source/appl | |
parent | f3a4129ed5946e2b8661dc8df23e00c4b6c6ecc8 (diff) |
convert remaining WarningBox to weld::MessageDialog
Change-Id: I7e3c156a6ad47ac232636ae274280c1cb7556d4a
Diffstat (limited to 'sfx2/source/appl')
-rw-r--r-- | sfx2/source/appl/opengrf.cxx | 11 |
1 files changed, 8 insertions, 3 deletions
diff --git a/sfx2/source/appl/opengrf.cxx b/sfx2/source/appl/opengrf.cxx index 6d190e45fce2..6698c1b70d99 100644 --- a/sfx2/source/appl/opengrf.cxx +++ b/sfx2/source/appl/opengrf.cxx @@ -39,7 +39,8 @@ #include <unotools/ucbstreamhelper.hxx> #include <svtools/transfer.hxx> #include <sot/formats.hxx> -#include <vcl/msgbox.hxx> +#include <vcl/svapp.hxx> +#include <vcl/weld.hxx> #include <sfx2/filedlghelper.hxx> #include <sfx2/docfile.hxx> #include <unotools/pathoptions.hxx> @@ -157,8 +158,12 @@ ErrCode SvxOpenGraphicDialog::Execute() // could not load? if ( nFound == USHRT_MAX ) { - ScopedVclPtrInstance< WarningBox > aWarningBox(nullptr, MessBoxStyle::RetryCancel, WB_3DLOOK, SfxResId( SvxOpenGrfErr2ResId(nImpRet) )); - bQuitLoop = aWarningBox->Execute() != RET_RETRY; + std::unique_ptr<weld::MessageDialog> xWarn(Application::CreateMessageDialog(nullptr, + VclMessageType::Warning, VclButtonsType::NONE, + SfxResId(SvxOpenGrfErr2ResId(nImpRet)))); + xWarn->add_button(Button::GetStandardText(StandardButtonType::Retry), RET_RETRY); + xWarn->add_button(Button::GetStandardText(StandardButtonType::Cancel), RET_CANCEL); + bQuitLoop = xWarn->run() != RET_RETRY; } else { |