diff options
author | Jocelyn Turcotte <jocelyn.turcotte@digia.com> | 2014-08-18 14:11:06 +0200 |
---|---|---|
committer | Jocelyn Turcotte <jocelyn.turcotte@digia.com> | 2014-08-20 17:13:51 +0200 |
commit | 7717f941a349140497d5e689530a2bf31e8397da (patch) | |
tree | 10a59c8fdc08bbaabc4c3b21500b56c259021f1a /src/core/render_widget_host_view_qt.h | |
parent | 7ea45766f6c49de9a81a387013fb1b98ab82766d (diff) |
Propagate the page's screen coordinates when the top-level window moved
This fixes a regression after the 37 upgrade where the select popups
would have the wrong position. Adjust to the new behavior and also
avoid doing a mapToGlobal of the position received in InitAsPopup.
RWHV::SetBounds has been giving us screen coordinates since the
Chromium 33 update, but popup locations somehow managed to work
properly through some side-effect sorcery.
This also fixes the value of window.screen[XY] in JavaScript which
wasn't updated when the window was moved.
Change-Id: I544499bafedccfb7d389b4abc48f1386c398473f
Reviewed-by: Pierre Rossi <pierre.rossi@gmail.com>
Diffstat (limited to 'src/core/render_widget_host_view_qt.h')
-rw-r--r-- | src/core/render_widget_host_view_qt.h | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/src/core/render_widget_host_view_qt.h b/src/core/render_widget_host_view_qt.h index acb1948a8..90a6ef87c 100644 --- a/src/core/render_widget_host_view_qt.h +++ b/src/core/render_widget_host_view_qt.h @@ -109,7 +109,7 @@ public: virtual void InitAsFullscreen(content::RenderWidgetHostView*) Q_DECL_OVERRIDE; virtual content::RenderWidgetHost* GetRenderWidgetHost() const Q_DECL_OVERRIDE; virtual void SetSize(const gfx::Size& size) Q_DECL_OVERRIDE; - virtual void SetBounds(const gfx::Rect& rect) Q_DECL_OVERRIDE; + virtual void SetBounds(const gfx::Rect&) Q_DECL_OVERRIDE; virtual gfx::Size GetPhysicalBackingSize() const Q_DECL_OVERRIDE; virtual gfx::NativeView GetNativeView() const Q_DECL_OVERRIDE; virtual gfx::NativeViewId GetNativeViewId() const Q_DECL_OVERRIDE; @@ -161,9 +161,10 @@ public: // Overridden from RenderWidgetHostViewQtDelegateClient. virtual QSGNode *updatePaintNode(QSGNode *) Q_DECL_OVERRIDE; virtual void notifyResize() Q_DECL_OVERRIDE; + virtual void windowBoundsChanged() Q_DECL_OVERRIDE; + virtual void windowChanged() Q_DECL_OVERRIDE; virtual bool forwardEvent(QEvent *) Q_DECL_OVERRIDE; virtual QVariant inputMethodQuery(Qt::InputMethodQuery query) const Q_DECL_OVERRIDE; - virtual void windowChanged() Q_DECL_OVERRIDE; void handleMouseEvent(QMouseEvent*); void handleKeyEvent(QKeyEvent*); |