summaryrefslogtreecommitdiffstats
path: root/webkit/glue
diff options
context:
space:
mode:
authorstuartmorgan@chromium.org <stuartmorgan@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2010-10-11 19:55:10 +0000
committerstuartmorgan@chromium.org <stuartmorgan@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2010-10-11 19:55:10 +0000
commit515040e36459a2f6b954e368f76abded22e8cef1 (patch)
treef26d352ecd0cc6260d61b31424fa4e642b7ec049 /webkit/glue
parent206c5b0f60cb328a34e964c4e5aaf788e2b084f4 (diff)
downloadchromium_src-515040e36459a2f6b954e368f76abded22e8cef1.zip
chromium_src-515040e36459a2f6b954e368f76abded22e8cef1.tar.gz
chromium_src-515040e36459a2f6b954e368f76abded22e8cef1.tar.bz2
Prevent implicit animation when resizing Core Animation plugins
BUG=None TEST=Open a page with an accelerated plugin (e.g., Unity). The pugin should not visibily animated to full size from the lower-left corner. Review URL: http://codereview.chromium.org/3649003 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@62177 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'webkit/glue')
-rw-r--r--webkit/glue/plugins/webplugin_delegate_impl_mac.mm5
1 files changed, 5 insertions, 0 deletions
diff --git a/webkit/glue/plugins/webplugin_delegate_impl_mac.mm b/webkit/glue/plugins/webplugin_delegate_impl_mac.mm
index e048eaf..11d244c 100644
--- a/webkit/glue/plugins/webplugin_delegate_impl_mac.mm
+++ b/webkit/glue/plugins/webplugin_delegate_impl_mac.mm
@@ -966,8 +966,13 @@ void WebPluginDelegateImpl::UpdateAcceleratedSurface() {
if (!windowed_handle() || !layer_)
return;
+ [CATransaction begin];
+ [CATransaction setValue:[NSNumber numberWithInt:0]
+ forKey:kCATransactionAnimationDuration];
[layer_ setFrame:CGRectMake(0, 0,
window_rect_.width(), window_rect_.height())];
+ [CATransaction commit];
+
[renderer_ setBounds:[layer_ bounds]];
surface_->SetSize(window_rect_.size());
}