sd/source/ui/slidesorter/controller/SlsSelectionFunction.cxx | 9 +++------ vcl/source/window/winproc.cxx | 3 ++- 2 files changed, 5 insertions(+), 7 deletions(-)
New commits: commit dfe7142cdd05707123c688b2a746bed63180ff52 Author: Caolán McNamara <[email protected]> Date: Tue May 17 13:38:46 2016 +0100 MouseClick -> MouseMove + MouseClick undesirably mimics a drag event when we click, if the click does not occur at the last known location of the mouse, we generate a mouse move event to this location, and then send the click event. But we are sending the move event with the current mouse-button held down state so it appears as a mini drag from the last known mouse location to the click site. This makes the slide pane in impress believe an attempt to drag a slide has occured, which is super annoying when trying to use the slide pane a lot. It would seem a more sensible thing to generate a move event with the buttons masked out and then continue to send the true button click afterwards. Change-Id: I5d0caf2cc1c9381800346f0b069af58123473cab diff --git a/vcl/source/window/winproc.cxx b/vcl/source/window/winproc.cxx index 3f3d0b2..d72d48e 100644 --- a/vcl/source/window/winproc.cxx +++ b/vcl/source/window/winproc.cxx @@ -289,7 +289,8 @@ bool ImplHandleMouseEvent( const VclPtr<vcl::Window>& xWindow, MouseNotifyEvent if ( (pWinFrameData->mnLastMouseX != nX) || (pWinFrameData->mnLastMouseY != nY) ) { - ImplHandleMouseEvent( xWindow, MouseNotifyEvent::MOUSEMOVE, false, nX, nY, nMsgTime, nCode, nMode ); + sal_uInt16 nMoveCode = nCode & ~(MOUSE_LEFT | MOUSE_RIGHT | MOUSE_MIDDLE); + ImplHandleMouseEvent(xWindow, MouseNotifyEvent::MOUSEMOVE, false, nX, nY, nMsgTime, nMoveCode, nMode); } } commit 5c3c69bb15d324d48f171ce2c3a3f3fea2f08958 Author: Caolán McNamara <[email protected]> Date: Tue May 17 12:41:14 2016 +0100 tidy this a little bit Change-Id: I32c03940f36acb6b70c7d846d6e9ffdba84b8807 diff --git a/sd/source/ui/slidesorter/controller/SlsSelectionFunction.cxx b/sd/source/ui/slidesorter/controller/SlsSelectionFunction.cxx index 6c2396e..0dc10f4 100644 --- a/sd/source/ui/slidesorter/controller/SlsSelectionFunction.cxx +++ b/sd/source/ui/slidesorter/controller/SlsSelectionFunction.cxx @@ -1179,11 +1179,8 @@ bool NormalModeHandler::ProcessMotionEvent ( bool bIsProcessed (true); switch (rDescriptor.mnEventCode) { - case ANY_MODIFIER(MOUSE_MOTION | LEFT_BUTTON | SINGLE_CLICK | OVER_UNSELECTED_PAGE): - // SetCurrentPage(rDescriptor.mpHitDescriptor); - // Fallthrough - // A mouse motion without visible substitution starts that. + case ANY_MODIFIER(MOUSE_MOTION | LEFT_BUTTON | SINGLE_CLICK | OVER_UNSELECTED_PAGE): case ANY_MODIFIER(MOUSE_MOTION | LEFT_BUTTON | SINGLE_CLICK | OVER_SELECTED_PAGE): { if (maButtonDownLocation) @@ -1200,10 +1197,10 @@ bool NormalModeHandler::ProcessMotionEvent ( ? InsertionIndicatorHandler::CopyMode : InsertionIndicatorHandler::MoveMode); } + break; } - break; - // A mouse motion not over a page starts a rectangle selection. + // A mouse motion not over a page starts a rectangle selection. case ANY_MODIFIER(MOUSE_MOTION | LEFT_BUTTON | SINGLE_CLICK | NOT_OVER_PAGE): mrSelectionFunction.SwitchToMultiSelectionMode( rDescriptor.maMouseModelPosition,
_______________________________________________ Libreoffice-commits mailing list [email protected] https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits
