diff options
Diffstat (limited to 'sw')
-rw-r--r-- | sw/source/uibase/docvw/edtdd.cxx | 10 | ||||
-rw-r--r-- | sw/source/uibase/docvw/edtwin.cxx | 2 | ||||
-rw-r--r-- | sw/source/uibase/inc/edtwin.hxx | 1 | ||||
-rw-r--r-- | sw/source/uibase/wrtsh/select.cxx | 1 |
4 files changed, 13 insertions, 1 deletions
diff --git a/sw/source/uibase/docvw/edtdd.cxx b/sw/source/uibase/docvw/edtdd.cxx index 8f86aa1d310a..278030c1f5ec 100644 --- a/sw/source/uibase/docvw/edtdd.cxx +++ b/sw/source/uibase/docvw/edtdd.cxx @@ -121,6 +121,16 @@ void SwEditWin::StartDrag( sal_Int8 /*nAction*/, const Point& rPosPixel ) if ( !bStart || m_bIsInDrag ) return; + // If the add selection mode has been pushed in the MouseButtonDown handler it needs to be + // popped or it will remain active and noticable in the statusbar selection control until the + // next MouseButtonUp event after the DnD, since a MouseButtonUp event is not received by the + // edit window when DnD is done. + if (g_bModePushed) + { + rSh.PopMode(); + g_bModePushed = false; + } + m_bMBPressed = false; ReleaseMouse(); g_bFrameDrag = false; diff --git a/sw/source/uibase/docvw/edtwin.cxx b/sw/source/uibase/docvw/edtwin.cxx index 744730d9942e..1729bbfdde8a 100644 --- a/sw/source/uibase/docvw/edtwin.cxx +++ b/sw/source/uibase/docvw/edtwin.cxx @@ -173,7 +173,7 @@ static bool g_bHoldSelection = false; bool g_bFrameDrag = false; static bool g_bValidCursorPos = false; -static bool g_bModePushed = false; +bool g_bModePushed = false; bool g_bDDTimerStarted = false; bool g_bDDINetAttr = false; static SdrHdlKind g_eSdrMoveHdl = SdrHdlKind::User; diff --git a/sw/source/uibase/inc/edtwin.hxx b/sw/source/uibase/inc/edtwin.hxx index e2a7ca97bcab..b5e09726a0b3 100644 --- a/sw/source/uibase/inc/edtwin.hxx +++ b/sw/source/uibase/inc/edtwin.hxx @@ -295,6 +295,7 @@ public: virtual FactoryFunction GetUITestFactory() const override; }; +extern bool g_bModePushed; extern bool g_bFrameDrag; extern bool g_bDDTimerStarted; extern bool g_bDDINetAttr; diff --git a/sw/source/uibase/wrtsh/select.cxx b/sw/source/uibase/wrtsh/select.cxx index 4cf35eb7d992..c955a8bdd174 100644 --- a/sw/source/uibase/wrtsh/select.cxx +++ b/sw/source/uibase/wrtsh/select.cxx @@ -55,6 +55,7 @@ void SwWrtShell::Invalidate() // to avoid making the slot volatile, invalidate it every time if something could have been changed // this is still much cheaper than asking for the state every 200 ms (and avoid background processing) GetView().GetViewFrame()->GetBindings().Invalidate( FN_STAT_SELMODE ); + GetView().GetViewFrame()->GetBindings().Update(FN_STAT_SELMODE); // make selection mode control icon update immediatly SwWordCountWrapper *pWrdCnt = static_cast<SwWordCountWrapper*>(GetView().GetViewFrame()->GetChildWindow(SwWordCountWrapper::GetChildWindowId())); if (pWrdCnt) pWrdCnt->UpdateCounts(); |