diff options
Diffstat (limited to 'src/plugins/platforms/wasm')
-rw-r--r-- | src/plugins/platforms/wasm/qwasmeventtranslator.cpp | 8 | ||||
-rw-r--r-- | src/plugins/platforms/wasm/qwasmeventtranslator.h | 4 |
2 files changed, 6 insertions, 6 deletions
diff --git a/src/plugins/platforms/wasm/qwasmeventtranslator.cpp b/src/plugins/platforms/wasm/qwasmeventtranslator.cpp index 3e6043b083..77decc970d 100644 --- a/src/plugins/platforms/wasm/qwasmeventtranslator.cpp +++ b/src/plugins/platforms/wasm/qwasmeventtranslator.cpp @@ -329,10 +329,10 @@ QWasmEventTranslator::QWasmEventTranslator(QWasmScreen *screen) , pressedButtons(Qt::NoButton) , resizeMode(QWasmWindow::ResizeNone) { - touchDevice = new QTouchDevice; - touchDevice->setType(QTouchDevice::TouchScreen); - touchDevice->setCapabilities(QTouchDevice::Position | QTouchDevice::Area | QTouchDevice::NormalizedPosition); - QWindowSystemInterface::registerTouchDevice(touchDevice); + touchDevice = new QPointingDevice; + touchDevice->setType(QInputDevice::DeviceType::TouchScreen); + touchDevice->setCapabilities(QPointingDevice::Capability::Position | QPointingDevice::Capability::Area | QPointingDevice::Capability::NormalizedPosition); + QWindowSystemInterface::registerInputDevice(touchDevice); initEventHandlers(); } diff --git a/src/plugins/platforms/wasm/qwasmeventtranslator.h b/src/plugins/platforms/wasm/qwasmeventtranslator.h index 568ae00732..f6c95770e9 100644 --- a/src/plugins/platforms/wasm/qwasmeventtranslator.h +++ b/src/plugins/platforms/wasm/qwasmeventtranslator.h @@ -35,7 +35,7 @@ #include <QtCore/qpoint.h> #include <emscripten/html5.h> #include "qwasmwindow.h" -#include <QtGui/qtouchdevice.h> +#include <QtGui/qpointingdevice.h> #include <QHash> QT_BEGIN_NAMESPACE @@ -88,7 +88,7 @@ private: QWasmWindow::ResizeMode resizeMode; QPoint resizePoint; QRect resizeStartRect; - QTouchDevice *touchDevice; + QPointingDevice *touchDevice; quint64 getTimestamp(); Qt::Key m_emDeadKey = Qt::Key_unknown; |