WebKit Bugzilla
New
Browse
Log In
×
Sign in with GitHub
or
Remember my login
Create Account
·
Forgot Password
Forgotten password account recovery
RESOLVED FIXED
110495
Plug-in snapshotting code always accepts first snapshot
https://bugs.webkit.org/show_bug.cgi?id=110495
Summary
Plug-in snapshotting code always accepts first snapshot
Dean Jackson
Reported
2013-02-21 11:58:31 PST
An HTMLPlugInImageElement swaps to a different renderer when it receives a snapshot from its embedding API (currently only WK2). This is a regression - previously we'd take a number of snapshots waiting for an image that had useful data, and there was a common renderer for the plugin and snapshot. This is the first part of the fix, which is to have the embedder tell the plugin when it thinks it has enough to snapshot. Only then will we swap to the other renderer. A later fix will be to make sure that we show intermediate (if mostly empty) snapshots.
Attachments
Patch
(6.08 KB, patch)
2013-02-21 12:08 PST
,
Dean Jackson
thorton
: review+
Details
Formatted Diff
Diff
View All
Add attachment
proposed patch, testcase, etc.
Dean Jackson
Comment 1
2013-02-21 12:08:59 PST
Created
attachment 189570
[details]
Patch
Tim Horton
Comment 2
2013-02-21 13:22:16 PST
Comment on
attachment 189570
[details]
Patch View in context:
https://bugs.webkit.org/attachment.cgi?id=189570&action=review
> Source/WebKit2/WebProcess/Plugins/PluginView.cpp:74 > -static const unsigned maximumSnapshotRetries = 60; > +static const unsigned maximumSnapshotRetries = 4;
I don't see an explanation for this change.
> Source/WebKit2/WebProcess/Plugins/PluginView.cpp:1609 > + m_pluginElement->setDisplayState(HTMLPlugInElement::DisplayingSnapshot);
When does the tear-down happen now?
Dean Jackson
Comment 3
2013-02-21 13:28:02 PST
Comment on
attachment 189570
[details]
Patch View in context:
https://bugs.webkit.org/attachment.cgi?id=189570&action=review
>> Source/WebKit2/WebProcess/Plugins/PluginView.cpp:74 >> +static const unsigned maximumSnapshotRetries = 4; > > I don't see an explanation for this change.
I will add this to the changelog: I also reduced the number of snapshot attempts we will make before giving up. We don't want to sit around for 66 seconds displaying nothing.
>> Source/WebKit2/WebProcess/Plugins/PluginView.cpp:1609 >> + m_pluginElement->setDisplayState(HTMLPlugInElement::DisplayingSnapshot); > > When does the tear-down happen now?
Oh, that happens anyway, because as soon as I set the displayState it will swap renderers. It was the existing renderer that had the Widget, and the reference to the PluginView, and so we tear things down in the destructor.
Dean Jackson
Comment 4
2013-02-21 13:57:36 PST
Committed
r143650
: <
http://trac.webkit.org/changeset/143650
>
Note
You need to
log in
before you can comment on or make changes to this bug.
Top of Page
Format For Printing
XML
Clone This Bug