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

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

Issue 118359: Don't call NPP_SetWindow before we have the plugin geometry. (Closed) Base URL: svn://chrome-svn/chrome/trunk/src/
Patch Set: '' Created 11 years, 6 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 | « chrome/common/render_messages.h ('k') | webkit/glue/webplugin.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: webkit/glue/plugins/webplugin_delegate_impl.cc
===================================================================
--- webkit/glue/plugins/webplugin_delegate_impl.cc (revision 17918)
+++ webkit/glue/plugins/webplugin_delegate_impl.cc (working copy)
@@ -740,10 +740,10 @@
DCHECK(!instance()->windowless());
- window_.clipRect.top = clip_rect_.y();
- window_.clipRect.left = clip_rect_.x();
- window_.clipRect.bottom = clip_rect_.y() + clip_rect_.height();
- window_.clipRect.right = clip_rect_.x() + clip_rect_.width();
+ window_.clipRect.top = std::max(0, clip_rect_.y());
+ window_.clipRect.left = std::max(0, clip_rect_.x());
+ window_.clipRect.bottom = std::max(0, clip_rect_.y() + clip_rect_.height());
+ window_.clipRect.right = std::max(0, clip_rect_.x() + clip_rect_.width());
window_.height = window_rect_.height();
window_.width = window_rect_.width();
window_.x = 0;
« no previous file with comments | « chrome/common/render_messages.h ('k') | webkit/glue/webplugin.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698