Kaydet (Commit) a4e58b50 authored tarafından Caolán McNamara's avatar Caolán McNamara

silence ReleaseMouse warning

Change-Id: I615b4877ab29075ed45149259260acfb2563cad8
üst c2f13bd8
...@@ -280,7 +280,7 @@ bool SelectionEngine::SelMouseButtonUp( const MouseEvent& rMEvt ) ...@@ -280,7 +280,7 @@ bool SelectionEngine::SelMouseButtonUp( const MouseEvent& rMEvt )
void SelectionEngine::ReleaseMouse() void SelectionEngine::ReleaseMouse()
{ {
if (!pWin) if (!pWin || !pWin->IsMouseCaptured())
return; return;
pWin->ReleaseMouse(); pWin->ReleaseMouse();
} }
......
...@@ -1251,7 +1251,8 @@ void ImplTBDragMgr::Dragging( const Point& rPos ) ...@@ -1251,7 +1251,8 @@ void ImplTBDragMgr::Dragging( const Point& rPos )
void ImplTBDragMgr::EndDragging( bool bOK ) void ImplTBDragMgr::EndDragging( bool bOK )
{ {
mpDragBox->HideTracking(); mpDragBox->HideTracking();
mpDragBox->ReleaseMouse(); if (mpDragBox->IsMouseCaptured())
mpDragBox->ReleaseMouse();
mpDragBox->mbDragging = false; mpDragBox->mbDragging = false;
mbShowDragRect = false; mbShowDragRect = false;
Application::RemoveAccel( &maAccel ); Application::RemoveAccel( &maAccel );
...@@ -3346,7 +3347,8 @@ void ToolBox::ImplFloatControl( bool bStart, FloatingWindow* pFloatWindow ) ...@@ -3346,7 +3347,8 @@ void ToolBox::ImplFloatControl( bool bStart, FloatingWindow* pFloatWindow )
mbDrag = false; mbDrag = false;
EndTracking(); EndTracking();
ReleaseMouse(); if (IsMouseCaptured())
ReleaseMouse();
} }
else else
{ {
......
...@@ -1335,7 +1335,8 @@ void ToolBox::EndSelection() ...@@ -1335,7 +1335,8 @@ void ToolBox::EndSelection()
if (mnCurPos != TOOLBOX_ITEM_NOTFOUND) if (mnCurPos != TOOLBOX_ITEM_NOTFOUND)
InvalidateItem(mnCurPos); InvalidateItem(mnCurPos);
EndTracking(); EndTracking();
ReleaseMouse(); if (IsMouseCaptured())
ReleaseMouse();
Deactivate(); Deactivate();
} }
...@@ -1378,7 +1379,8 @@ void ToolBox::SetItemDown( sal_uInt16 nItemId, bool bDown, bool bRelease ) ...@@ -1378,7 +1379,8 @@ void ToolBox::SetItemDown( sal_uInt16 nItemId, bool bDown, bool bRelease )
mbDrag = false; mbDrag = false;
mbSelection = false; mbSelection = false;
EndTracking(); EndTracking();
ReleaseMouse(); if (IsMouseCaptured())
ReleaseMouse();
Deactivate(); Deactivate();
} }
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment