RESOLVED FIXED 39457
REGRESSION(r53637): DivX plug-in fails to start until window is resized
https://bugs.webkit.org/show_bug.cgi?id=39457
Summary REGRESSION(r53637): DivX plug-in fails to start until window is resized
Jon Honeycutt
Reported 2010-05-20 16:47:15 PDT
The video on the page above doesn't start playing until the window is resized. <rdar://problem/8006102>
Attachments
patch (3.32 KB, patch)
2010-05-20 17:44 PDT, Jon Honeycutt
no flags
patch v2 (5.03 KB, patch)
2010-05-20 19:18 PDT, Jon Honeycutt
simon.fraser: review+
Jon Honeycutt
Comment 1 2010-05-20 17:44:02 PDT
Simon Fraser (smfr)
Comment 2 2010-05-20 18:26:32 PDT
Comment on attachment 56652 [details] patch > diff --git a/WebCore/plugins/win/PluginViewWin.cpp b/WebCore/plugins/win/PluginViewWin.cpp > index 96fa9e4..baef667 100644 > --- a/WebCore/plugins/win/PluginViewWin.cpp > +++ b/WebCore/plugins/win/PluginViewWin.cpp > @@ -610,6 +610,9 @@ void PluginView::paint(GraphicsContext* context, const IntRect& rect) > if (context->paintingDisabled()) > return; > > + // Ensure that we have called SetWindow before we try to paint. > + setNPWindowRect(frameRect()); Plugins may do significant work every time setWindow() is called. Can we be smarter about detecting when it needs to be called (e.g .by remembering the last frameRect that we called it with)?
Jon Honeycutt
Comment 3 2010-05-20 19:02:41 PDT
(In reply to comment #2) > (From update of attachment 56652 [details]) > > diff --git a/WebCore/plugins/win/PluginViewWin.cpp b/WebCore/plugins/win/PluginViewWin.cpp > > index 96fa9e4..baef667 100644 > > --- a/WebCore/plugins/win/PluginViewWin.cpp > > +++ b/WebCore/plugins/win/PluginViewWin.cpp > > @@ -610,6 +610,9 @@ void PluginView::paint(GraphicsContext* context, const IntRect& rect) > > if (context->paintingDisabled()) > > return; > > > > + // Ensure that we have called SetWindow before we try to paint. > > + setNPWindowRect(frameRect()); > > Plugins may do significant work every time setWindow() is called. Can we be smarter about detecting when it needs to be called (e.g .by remembering the last frameRect that we called it with)? I'm not sure why setNPWindowRect() doesn't already do this, but I'm wary about changing that. To fix this bug, it should only be necessary to call setNPWindowRect here if we haven't called NPP_SetWindow yet. I'll update the patch to do that.
Jon Honeycutt
Comment 4 2010-05-20 19:18:36 PDT
Created attachment 56661 [details] patch v2
Jon Honeycutt
Comment 5 2010-05-20 20:21:20 PDT
Landed in r59904.
Note You need to log in before you can comment on or make changes to this bug.