summaryrefslogtreecommitdiffstats
path: root/src/plugins/platforms/windows/qwindowscontext.cpp
diff options
context:
space:
mode:
authorSérgio Martins <sergio.martins@kdab.com>2015-03-25 13:37:31 +0000
committerSérgio Martins <sergio.martins@kdab.com>2015-03-26 14:57:45 +0000
commitf451d4800595caf00b6aa61408006cd100a6d416 (patch)
tree70d194ceb890279872ea3c60d17bfb1051b2185a /src/plugins/platforms/windows/qwindowscontext.cpp
parenteea5a6ea15651a4bc2d0d1b1f45a2542a26083d0 (diff)
Windows: Add support for horizontal scroll on some touchpads.
While most (all?) touchpads send WM_MOUSEWHEEL for vertical scroll the story is quite different for horizontal scroll. Some of them send WM_HSCROLL instead of WM_MOUSEHWHEEL. Some of them even send left/right key event but those are lost cases. Task-number: QTBUG-45120 Change-Id: I3bf86e25a6f4f3ba03ac7e89a23f4b7bc432f2de Reviewed-by: Friedemann Kleint <Friedemann.Kleint@theqtcompany.com>
Diffstat (limited to 'src/plugins/platforms/windows/qwindowscontext.cpp')
-rw-r--r--src/plugins/platforms/windows/qwindowscontext.cpp6
1 files changed, 6 insertions, 0 deletions
diff --git a/src/plugins/platforms/windows/qwindowscontext.cpp b/src/plugins/platforms/windows/qwindowscontext.cpp
index 72bfeec143..bcd3922773 100644
--- a/src/plugins/platforms/windows/qwindowscontext.cpp
+++ b/src/plugins/platforms/windows/qwindowscontext.cpp
@@ -1032,6 +1032,12 @@ bool QWindowsContext::windowsProc(HWND hwnd, UINT message,
return true;
}
#endif
+ case QtWindows::ScrollEvent:
+#if !defined(Q_OS_WINCE) && !defined(QT_NO_SESSIONMANAGER)
+ return platformSessionManager()->isInteractionBlocked() ? true : d->m_mouseHandler.translateScrollEvent(platformWindow->window(), hwnd, msg, result);
+#else
+ return d->m_mouseHandler.translateScrollEvent(platformWindow->window(), hwnd, msg, result);
+#endif
case QtWindows::MouseWheelEvent:
case QtWindows::MouseEvent:
case QtWindows::LeaveEvent: