From 32deec6509deb789265c50ba2943bc575b7f547c Mon Sep 17 00:00:00 2001 From: "lazyboy@chromium.org" Date: Wed, 15 May 2013 23:55:04 +0000 Subject: Make renderer aware of browser plugin position. We need to send updated screen rects to renderer whenever the embedder's browser side has screen rect updates. This informs webkit/renderer about the correct position of browser plugin. Fix view bounds/coordinates for RWHViewGuest. Both changes together should fix a) datalist/html5 popups appearing in correct position: i. initially, ii: after moving app window, iii: after resizing app window. b) window.screenX/Y/Left/Top for guests as well. BUG=233285, 226653 TEST=Added tests, ran them on trybots. Ran PopupPositioning test in trybot for 50 times on each run, still found few flaky occurrences, will work on it more. Review URL: https://chromiumcodereview.appspot.com/14123006 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@200393 0039d316-1c4b-4281-b951-d872f2087c98 --- content/browser/web_contents/web_contents_impl.cc | 5 +++++ 1 file changed, 5 insertions(+) (limited to 'content/browser/web_contents/web_contents_impl.cc') diff --git a/content/browser/web_contents/web_contents_impl.cc b/content/browser/web_contents/web_contents_impl.cc index 4969576..d8e4d6e2 100644 --- a/content/browser/web_contents/web_contents_impl.cc +++ b/content/browser/web_contents/web_contents_impl.cc @@ -1596,6 +1596,11 @@ void WebContentsImpl::RequestMediaAccessPermission( callback.Run(MediaStreamDevices(), scoped_ptr()); } +void WebContentsImpl::DidSendScreenRects(RenderWidgetHostImpl* rwh) { + if (browser_plugin_embedder_) + browser_plugin_embedder_->DidSendScreenRects(rwh); +} + void WebContentsImpl::UpdatePreferredSize(const gfx::Size& pref_size) { preferred_size_ = pref_size; if (delegate_) -- cgit v1.1