summaryrefslogtreecommitdiffstats
path: root/src/webenginewidgets/render_widget_host_view_qt_delegate_widget.cpp
diff options
context:
space:
mode:
authorJüri Valdmann <juri.valdmann@qt.io>2020-07-15 11:56:00 +0200
committerJüri Valdmann <juri.valdmann@qt.io>2020-08-13 12:33:48 +0200
commit0c0500717e3bb329ceeef764fd6b962af10488cf (patch)
tree5abffa55b82c49f0f59e7779b4509d58d0e063a4 /src/webenginewidgets/render_widget_host_view_qt_delegate_widget.cpp
parent5189f03b0078567f6a0c1fa32780314cb7451102 (diff)
Fix almost all deprecation warnings
Replace QString::fromUtf16({const ushort * -> const char16_t}) QMap::{unite -> insert} Q{Hover,DragEnter,DragMove,Drop}Event::{posF() -> position()} Q{Hover,DragEnter,DragMove,Drop}Event::{pos() -> position().toPoint()} Q{DragEnter,Drop}Event::{mouseButtons -> buttons} Q{DragEnter,Drop}Event::{keyboardModifiers -> modifiers} QMouseEvent::{localPos -> position} QMouseEvent::{windowPos -> scenePosition} QMouseEvent::{screenPos -> globalPosition} These should all be just renames without any change in behavior (save for some floating point conversions). The one remaining issue concerns the deprecation of binary JSON in qtbase, which is recommended to be replaced with CBOR. Change-Id: I8f3b533242fe9a58c08c2b09ff5d0bdbbfa6dd17 Reviewed-by: Allan Sandfeld Jensen <allan.jensen@qt.io>
Diffstat (limited to 'src/webenginewidgets/render_widget_host_view_qt_delegate_widget.cpp')
-rw-r--r--src/webenginewidgets/render_widget_host_view_qt_delegate_widget.cpp5
1 files changed, 3 insertions, 2 deletions
diff --git a/src/webenginewidgets/render_widget_host_view_qt_delegate_widget.cpp b/src/webenginewidgets/render_widget_host_view_qt_delegate_widget.cpp
index af30c54b8..0fd425580 100644
--- a/src/webenginewidgets/render_widget_host_view_qt_delegate_widget.cpp
+++ b/src/webenginewidgets/render_widget_host_view_qt_delegate_widget.cpp
@@ -441,8 +441,9 @@ bool RenderWidgetHostViewQtDelegateWidget::event(QEvent *event)
// QtQuick is different by sending both the Press and DblClick events for the second press
// where we can simply ignore the DblClick event.
QMouseEvent *dblClick = static_cast<QMouseEvent *>(event);
- QMouseEvent press(QEvent::MouseButtonPress, dblClick->localPos(), dblClick->windowPos(), dblClick->screenPos(),
- dblClick->button(), dblClick->buttons(), dblClick->modifiers(), dblClick->source());
+ QMouseEvent press(QEvent::MouseButtonPress, dblClick->position(), dblClick->scenePosition(),
+ dblClick->globalPosition(), dblClick->button(), dblClick->buttons(),
+ dblClick->modifiers(), dblClick->source());
press.setTimestamp(dblClick->timestamp());
handled = m_client->forwardEvent(&press);
} else