summaryrefslogtreecommitdiff
path: root/sc/source/ui/docshell/impex.cxx
diff options
context:
space:
mode:
Diffstat (limited to 'sc/source/ui/docshell/impex.cxx')
-rw-r--r--sc/source/ui/docshell/impex.cxx9
1 files changed, 6 insertions, 3 deletions
diff --git a/sc/source/ui/docshell/impex.cxx b/sc/source/ui/docshell/impex.cxx
index 146c097626e1..e39abc0dc479 100644
--- a/sc/source/ui/docshell/impex.cxx
+++ b/sc/source/ui/docshell/impex.cxx
@@ -57,6 +57,7 @@
#include <tools/svlibrary.h>
#include <unotools/configmgr.hxx>
#include <vcl/svapp.hxx>
+#include <vcl/weld.hxx>
#include <memory>
#include <osl/endian.h>
@@ -227,9 +228,11 @@ bool ScImportExport::StartPaste()
ScEditableTester aTester( pDoc, aRange );
if ( !aTester.IsEditable() )
{
- ScopedVclPtrInstance<InfoBox> aInfoBox( Application::GetDefDialogParent(),
- ScGlobal::GetRscString( aTester.GetMessageId() ) );
- aInfoBox->Execute();
+ vcl::Window* pWin = Application::GetDefDialogParent();
+ std::unique_ptr<weld::MessageDialog> xInfoBox(Application::CreateMessageDialog(pWin ? pWin->GetFrameWeld() : nullptr,
+ VclMessageType::Info, VclButtonsType::Ok,
+ ScGlobal::GetRscString(aTester.GetMessageId())));
+ xInfoBox->run();
return false;
}
}