From de7ffee747e044c7afae2a4678a5fea06be17866 Mon Sep 17 00:00:00 2001 From: Gatis Paeglis Date: Wed, 30 Aug 2017 14:13:35 +0200 Subject: evdevtablet: don't use qpa compatibility function This patch does not attempt to add the necessary functionality to support other tablet buttons, it simply replaces deprecated version of QWindowSystemInterface::handleTabletEvent(), by keeping the previous logic. Task-number: QTBUG-62886 Change-Id: I23597077774d482492136fda2e998700f8b27e9c Reviewed-by: Laszlo Agocs --- src/platformsupport/input/evdevtablet/qevdevtablethandler.cpp | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) (limited to 'src/platformsupport/input') diff --git a/src/platformsupport/input/evdevtablet/qevdevtablethandler.cpp b/src/platformsupport/input/evdevtablet/qevdevtablethandler.cpp index cfc17a79c3..dbab2f6a24 100644 --- a/src/platformsupport/input/evdevtablet/qevdevtablethandler.cpp +++ b/src/platformsupport/input/evdevtablet/qevdevtablethandler.cpp @@ -149,9 +149,11 @@ void QEvdevTabletData::report() qreal pressure = pressureRange ? (state.p - minValues.p) / qreal(pressureRange) : qreal(1); if (state.down || state.lastReportDown) { - QWindowSystemInterface::handleTabletEvent(0, state.down, QPointF(), globalPos, + QWindowSystemInterface::handleTabletEvent(0, QPointF(), globalPos, QTabletEvent::Stylus, pointer, - pressure, 0, 0, 0, 0, 0, q->deviceId(), qGuiApp->keyboardModifiers()); + state.down ? Qt::LeftButton : Qt::NoButton, + pressure, 0, 0, 0, 0, 0, q->deviceId(), + qGuiApp->keyboardModifiers()); } if (state.lastReportTool && !state.tool) -- cgit v1.2.3