summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorQt Forward Merge Bot <qt_forward_merge_bot@qt-project.org>2019-12-03 03:03:32 +0100
committerQt Forward Merge Bot <qt_forward_merge_bot@qt-project.org>2019-12-03 03:03:32 +0100
commit9c3df6579763e2bd45e51a1f5e7d276947b85f6f (patch)
tree3094a94c6a39a08d0ce3cb0d0aab9e77045d6fd7
parent781e5c02ec779ef73695b314182f4a2d6b788cf5 (diff)
parentd4c5e69944a48407d50fbe42c1af4be9bb8c4b87 (diff)
Merge remote-tracking branch 'origin/5.15' into dev
-rw-r--r--src/plugins/platforms/webgl/qwebglintegration.cpp10
-rw-r--r--src/plugins/platforms/webgl/qwebglwindow.cpp5
-rw-r--r--src/plugins/platforms/webgl/webqt.jsx4
3 files changed, 8 insertions, 11 deletions
diff --git a/src/plugins/platforms/webgl/qwebglintegration.cpp b/src/plugins/platforms/webgl/qwebglintegration.cpp
index 645c766..5031e5e 100644
--- a/src/plugins/platforms/webgl/qwebglintegration.cpp
+++ b/src/plugins/platforms/webgl/qwebglintegration.cpp
@@ -493,10 +493,10 @@ void QWebGLIntegrationPrivate::handleMouse(const ClientData &clientData, const Q
QPointF globalPos(object.value("clientX").toDouble(),
object.value("clientY").toDouble());
auto buttons = static_cast<Qt::MouseButtons>(object.value("buttons").toInt());
- auto time = object.value("time").toDouble();
+ auto time = object.value("time").toString();
auto platformWindow = findWindow(clientData, winId);
QWindowSystemInterface::handleMouseEvent(platformWindow->window(),
- static_cast<ulong>(time),
+ time.toULong(),
localPos,
globalPos,
Qt::MouseButtons(buttons),
@@ -535,11 +535,11 @@ void QWebGLIntegrationPrivate::handleTouch(const ClientData &clientData, const Q
const auto winId = object.value("name").toInt(-1);
Q_ASSERT(winId != -1);
auto window = findWindow(clientData, winId)->window();
- const auto time = object.value("time").toDouble();
+ const auto time = object.value("time").toString();
const auto eventType = object.value("event").toString();
if (eventType == QStringLiteral("touchcancel")) {
QWindowSystemInterface::handleTouchCancelEvent(window,
- time,
+ time.toULong(),
touchDevice,
Qt::NoModifier);
} else {
@@ -585,7 +585,7 @@ void QWebGLIntegrationPrivate::handleTouch(const ClientData &clientData, const Q
}
QWindowSystemInterface::handleTouchEvent(window,
- time,
+ time.toULong(),
touchDevice,
points,
Qt::NoModifier);
diff --git a/src/plugins/platforms/webgl/qwebglwindow.cpp b/src/plugins/platforms/webgl/qwebglwindow.cpp
index 8b2af2e..ed26f08 100644
--- a/src/plugins/platforms/webgl/qwebglwindow.cpp
+++ b/src/plugins/platforms/webgl/qwebglwindow.cpp
@@ -58,9 +58,6 @@ QWebGLWindow::QWebGLWindow(QWindow *w) :
QPlatformWindow(w),
d_ptr(new QWebGLWindowPrivate(this))
{
- Q_D(QWebGLWindow);
- d->raster = false;
- d->flags = 0;
}
QWebGLWindow::~QWebGLWindow()
@@ -118,7 +115,7 @@ void QWebGLWindow::destroy()
qt_window_private(window())->updateRequestPending = false;
- d->flags = 0;
+ d->flags = QWebGLWindowPrivate::Flags{};
auto integrationPrivate = QWebGLIntegrationPrivate::instance();
auto clientData = integrationPrivate->findClientData(surface()->surfaceHandle());
diff --git a/src/plugins/platforms/webgl/webqt.jsx b/src/plugins/platforms/webgl/webqt.jsx
index ca2b3b5..02f93a5 100644
--- a/src/plugins/platforms/webgl/webqt.jsx
+++ b/src/plugins/platforms/webgl/webqt.jsx
@@ -212,7 +212,7 @@ window.onload = function () {
var object = { "type": "mouse",
"buttons": buttons,
"layerX": layerX, "layerY": layerY, "clientX": clientX, "clientY": clientY,
- "time": new Date().getTime(),
+ "time": new Date().getTime().toString(),
"name": name
};
sendObject(object);
@@ -285,7 +285,7 @@ window.onload = function () {
var object = {
"type": "touch",
"name": name,
- "time": new Date().getTime(),
+ "time": new Date().getTime().toString(),
"event": event.type,
"changedTouches": [],
"stationaryTouches": [],