summaryrefslogtreecommitdiffstats
path: root/chrome/renderer/webplugin_delegate_proxy.cc
diff options
context:
space:
mode:
authorstuartmorgan@chromium.org <stuartmorgan@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2010-03-11 19:36:29 +0000
committerstuartmorgan@chromium.org <stuartmorgan@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2010-03-11 19:36:29 +0000
commitcb63c05d1198b8bb61b01cb057a1345acf5be853 (patch)
tree83db1a759572cf29e8f3a4db52f59502108d7ad1 /chrome/renderer/webplugin_delegate_proxy.cc
parent9ea9ca45885eeb653d041a7f828ee8880ae4926a (diff)
downloadchromium_src-cb63c05d1198b8bb61b01cb057a1345acf5be853.zip
chromium_src-cb63c05d1198b8bb61b01cb057a1345acf5be853.tar.gz
chromium_src-cb63c05d1198b8bb61b01cb057a1345acf5be853.tar.bz2
Make sure Core Animation plugins get initial geometry
BUG=32012 TEST=Once CA plugins are enabled, they should display immediately, without having to resize or scroll the window. Review URL: http://codereview.chromium.org/854004 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@41309 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'chrome/renderer/webplugin_delegate_proxy.cc')
-rw-r--r--chrome/renderer/webplugin_delegate_proxy.cc12
1 files changed, 12 insertions, 0 deletions
diff --git a/chrome/renderer/webplugin_delegate_proxy.cc b/chrome/renderer/webplugin_delegate_proxy.cc
index 10bf1f8..532d26f 100644
--- a/chrome/renderer/webplugin_delegate_proxy.cc
+++ b/chrome/renderer/webplugin_delegate_proxy.cc
@@ -1279,6 +1279,18 @@ bool WebPluginDelegateProxy::BindFakePluginWindowHandle() {
fake_window))) {
return false;
}
+
+ // Since this isn't a real window, it doesn't get initial size and location
+ // information the way a real windowed plugin would, so we need to feed it its
+ // starting geometry.
+ webkit_glue::WebPluginGeometry geom;
+ geom.window = fake_window;
+ geom.window_rect = plugin_rect_;
+ geom.clip_rect = gfx::Rect(0, 0, plugin_rect_.width(), plugin_rect_.height());
+ geom.rects_valid = true;
+ geom.visible = true;
+ render_view_->DidMovePlugin(geom);
+
return true;
}
#endif