diff options
author | Caolán McNamara <caolanm@redhat.com> | 2019-05-11 21:42:04 +0100 |
---|---|---|
committer | Caolán McNamara <caolanm@redhat.com> | 2019-05-12 17:36:02 +0200 |
commit | 7cfacfd4e990d5b8fd2cb3045cf632b9dd957023 (patch) | |
tree | 4417a84e121cf3f8a29ef80b1cf7267209135092 /sc/source/ui/view/viewfun3.cxx | |
parent | 038e4b3b1e10d072b432cb06234521ae9a262a70 (diff) |
drop intermediate vcl::Window
Change-Id: If06902f0308511fb40b031899c912c36da0b610e
Reviewed-on: https://gerrit.libreoffice.org/72167
Tested-by: Jenkins
Reviewed-by: Caolán McNamara <caolanm@redhat.com>
Tested-by: Caolán McNamara <caolanm@redhat.com>
Diffstat (limited to 'sc/source/ui/view/viewfun3.cxx')
-rw-r--r-- | sc/source/ui/view/viewfun3.cxx | 12 |
1 files changed, 4 insertions, 8 deletions
diff --git a/sc/source/ui/view/viewfun3.cxx b/sc/source/ui/view/viewfun3.cxx index 84cbdcfe9a5e..2dbc3e9a55a8 100644 --- a/sc/source/ui/view/viewfun3.cxx +++ b/sc/source/ui/view/viewfun3.cxx @@ -1062,8 +1062,7 @@ bool ScViewFunc::PasteFromClip( InsertDeleteFlags nFlags, ScDocument* pClipDoc, ScWaitCursorOff aWaitOff( GetFrameWin() ); OUString aMessage = ScResId( STR_PASTE_BIGGER ); - vcl::Window* pWin = GetViewData().GetDialogParent(); - std::unique_ptr<weld::MessageDialog> xQueryBox(Application::CreateMessageDialog(pWin ? pWin->GetFrameWeld() : nullptr, + std::unique_ptr<weld::MessageDialog> xQueryBox(Application::CreateMessageDialog(GetViewData().GetFrameWeld(), VclMessageType::Question, VclButtonsType::YesNo, aMessage)); xQueryBox->set_default_response(RET_NO); @@ -1151,8 +1150,7 @@ bool ScViewFunc::PasteFromClip( InsertDeleteFlags nFlags, ScDocument* pClipDoc, if ( bAskIfNotEmpty ) { ScRangeList aTestRanges(aUserRange); - vcl::Window* pWin = GetViewData().GetDialogParent(); - if (!checkDestRangeForOverwrite(aTestRanges, pDoc, aFilteredMark, pWin ? pWin->GetFrameWeld() : nullptr)) + if (!checkDestRangeForOverwrite(aTestRanges, pDoc, aFilteredMark, GetViewData().GetFrameWeld())) return false; } } @@ -1519,8 +1517,7 @@ bool ScViewFunc::PasteMultiRangesFromClip( if (bAskIfNotEmpty) { ScRangeList aTestRanges(aMarkedRange); - vcl::Window* pWin = GetViewData().GetDialogParent(); - if (!checkDestRangeForOverwrite(aTestRanges, pDoc, aMark, pWin ? pWin->GetFrameWeld() : nullptr)) + if (!checkDestRangeForOverwrite(aTestRanges, pDoc, aMark, GetViewData().GetFrameWeld())) return false; } @@ -1682,8 +1679,7 @@ bool ScViewFunc::PasteFromClipToMultiRanges( if (bAskIfNotEmpty) { - vcl::Window* pWin = GetViewData().GetDialogParent(); - if (!checkDestRangeForOverwrite(aRanges, pDoc, aMark, pWin ? pWin->GetFrameWeld() : nullptr)) + if (!checkDestRangeForOverwrite(aRanges, pDoc, aMark, GetViewData().GetFrameWeld())) return false; } |