Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(18)

Unified Diff: webkit/glue/plugins/webplugin_delegate_impl_gtk.cc

Issue 159689: linux: don't call NPP_SetWindow if the width/height is <= 0 (Closed)
Patch Set: Created 11 years, 5 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: webkit/glue/plugins/webplugin_delegate_impl_gtk.cc
diff --git a/webkit/glue/plugins/webplugin_delegate_impl_gtk.cc b/webkit/glue/plugins/webplugin_delegate_impl_gtk.cc
index d107a6d4b977da0c64ed6bf81cf41950183c6aa2..0e394cedac640bbd764abc64a88778817f5296ba 100644
--- a/webkit/glue/plugins/webplugin_delegate_impl_gtk.cc
+++ b/webkit/glue/plugins/webplugin_delegate_impl_gtk.cc
@@ -315,6 +315,15 @@ void WebPluginDelegateImpl::WindowedSetWindow() {
return;
}
+ // See https://bugzilla.mozilla.org/show_bug.cgi?id=108347
+ // If we call NPP_SetWindow with a <= 0 width or height, problems arise in
+ // Flash (and possibly other plugins).
+ // TODO(piman): the Mozilla code suggests that for the Java plugin, we should
+ // still call NPP_SetWindow in that case. We need to verify that.
+ if (window_rect_.width() <= 0 || window_rect_.height() <= 0) {
+ return;
+ }
+
instance()->set_window_handle(windowed_handle_);
DCHECK(!instance()->windowless());
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698