summaryrefslogtreecommitdiff
path: root/sc
diff options
context:
space:
mode:
authorCaolán McNamara <caolanm@redhat.com>2019-11-18 20:55:54 +0000
committerCaolán McNamara <caolanm@redhat.com>2019-11-19 09:53:35 +0100
commit1aaa229af711fe5deeaaabf22c1e32c3025e1bf5 (patch)
tree98ca15e19d3cc5ec59b032b05b4f98458809d4fb /sc
parent752cc49c97b9c88f37d9a451050beaeab2d2e5cf (diff)
Related: tdf#125917 release mouse grab before showing warning dialog
Type text into the data validity dropdown cell and click elsewhere. The warning dialog cannot be interacted with due to the active mouse grab to its parent Change-Id: I51702c828dee6ec88106f7d44d7e3440f2e61298 Reviewed-on: https://gerrit.libreoffice.org/83128 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolanm@redhat.com> Tested-by: Caolán McNamara <caolanm@redhat.com>
Diffstat (limited to 'sc')
-rw-r--r--sc/source/ui/app/inputhdl.cxx11
1 files changed, 11 insertions, 0 deletions
diff --git a/sc/source/ui/app/inputhdl.cxx b/sc/source/ui/app/inputhdl.cxx
index d7b016726c8d..feac54132690 100644
--- a/sc/source/ui/app/inputhdl.cxx
+++ b/sc/source/ui/app/inputhdl.cxx
@@ -2791,8 +2791,19 @@ void ScInputHandler::EnterHandler( ScEnterMode nBlockMode )
if (!bOk)
{
if ( pActiveViewSh ) // If it came from MouseButtonDown
+ {
pActiveViewSh->StopMarking(); // (the InfoBox consumes the MouseButtonUp)
+ // tdf#125917 Release the grab the a current mouse-down event being handled
+ // by ScTabView has put on the mouse via its SelectionEngine.
+ // Otherwise the warning box cannot interact with the mouse
+ if (ScTabView* pView = pActiveViewSh->GetViewData().GetView())
+ {
+ if (ScViewSelectionEngine* pSelEngine = pView->GetSelEngine())
+ pSelEngine->ReleaseMouse();
+ }
+ }
+
vcl::Window* pParent = nullptr;
if (pActiveViewSh)
pParent = &pActiveViewSh->GetViewFrame()->GetWindow();