From a94a3098d0cc82a850d2d0c62baad6edef72e142 Mon Sep 17 00:00:00 2001 From: Andre de la Rocha Date: Wed, 14 Nov 2018 12:49:00 +0100 Subject: Windows QPA: Fix building with -no-feature-tabletevent This change fixes building Qt with the -no-feature-tabletevent configure option by disabling handling of pointer messages associated with tablet events within the pointer message handler. Fixes: QTBUG-71774 Change-Id: Icb47a39793edb9a0f87c07c656b6ea6573d5f947 Reviewed-by: Friedemann Kleint --- src/plugins/platforms/windows/qwindowspointerhandler.cpp | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/src/plugins/platforms/windows/qwindowspointerhandler.cpp b/src/plugins/platforms/windows/qwindowspointerhandler.cpp index 2b6c696979..d88049019b 100644 --- a/src/plugins/platforms/windows/qwindowspointerhandler.cpp +++ b/src/plugins/platforms/windows/qwindowspointerhandler.cpp @@ -609,6 +609,7 @@ bool QWindowsPointerHandler::translateTouchEvent(QWindow *window, HWND hwnd, bool QWindowsPointerHandler::translatePenEvent(QWindow *window, HWND hwnd, QtWindows::WindowsEventType et, MSG msg, PVOID vPenInfo) { +#if QT_CONFIG(tabletevent) if (et & QtWindows::NonClientEventFlag) return false; // Let DefWindowProc() handle Non Client messages. @@ -703,6 +704,14 @@ bool QWindowsPointerHandler::translatePenEvent(QWindow *window, HWND hwnd, QtWin } } return true; +#else + Q_UNUSED(window); + Q_UNUSED(hwnd); + Q_UNUSED(et); + Q_UNUSED(msg); + Q_UNUSED(vPenInfo); + return false; +#endif } // Process old-style mouse messages here. -- cgit v1.2.3