summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-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();