From 72610099ae39fa158da2fac220608f015a621fc1 Mon Sep 17 00:00:00 2001 From: David Capello <davidcapello@gmail.com> Date: Fri, 10 Nov 2017 19:07:50 -0300 Subject: [PATCH] win8: the first touch w/fingers now move the mouse cursor --- src/she/win/window.cpp | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/src/she/win/window.cpp b/src/she/win/window.cpp index 04afb2546..f8984ad5f 100644 --- a/src/she/win/window.cpp +++ b/src/she/win/window.cpp @@ -1224,6 +1224,11 @@ void WinWindow::handleInteractionContextOutput( gfx::Point delta(-int(output->arguments.manipulation.delta.translationX) / m_scale, -int(output->arguments.manipulation.delta.translationY) / m_scale); + if (output->interactionFlags & INTERACTION_FLAG_BEGIN) { + ev.setType(Event::MouseMove); + queueEvent(ev); + } + ev.setType(Event::MouseWheel); ev.setWheelDelta(delta); ev.setPreciseWheel(true); @@ -1237,7 +1242,9 @@ void WinWindow::handleInteractionContextOutput( case INTERACTION_ID_TAP: MOUSE_TRACE(" - count=%d\n", output->arguments.tap.count); + ev.setButton(Event::LeftButton); + ev.setType(Event::MouseMove); queueEvent(ev); if (output->arguments.tap.count == 2) { ev.setType(Event::MouseDoubleClick); queueEvent(ev); } @@ -1250,6 +1257,7 @@ void WinWindow::handleInteractionContextOutput( case INTERACTION_ID_SECONDARY_TAP: case INTERACTION_ID_HOLD: ev.setButton(Event::RightButton); + ev.setType(Event::MouseMove); queueEvent(ev); ev.setType(Event::MouseDown); queueEvent(ev); ev.setType(Event::MouseUp); queueEvent(ev); break;