Bug 107019 - Web Inspector: [Canvas] introduce Resource.toDataURL
Summary: Web Inspector: [Canvas] introduce Resource.toDataURL
Status: RESOLVED FIXED
Alias: None
Product: WebKit
Classification: Unclassified
Component: Web Inspector (Deprecated) (show other bugs)
Version: 528+ (Nightly build)
Hardware: All All
: P2 Normal
Assignee: Andrey Adaikin
URL:
Keywords:
Depends on:
Blocks: 107274
  Show dependency treegraph
 
Reported: 2013-01-16 08:47 PST by Andrey Adaikin
Modified: 2013-01-18 07:13 PST (History)
9 users (show)

See Also:


Attachments
Patch (13.80 KB, patch)
2013-01-16 08:51 PST, Andrey Adaikin
no flags Details | Formatted Diff | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Andrey Adaikin 2013-01-16 08:47:50 PST
Resource.toDataURL will return string data url representation of a resource, if applicable. For example, for a rendering context resource (2D or WebGL) it will return canvas.toDataURL().

Patch to follow.
Comment 1 Andrey Adaikin 2013-01-16 08:51:10 PST
Created attachment 182992 [details]
Patch
Comment 2 Pavel Feldman 2013-01-18 06:02:36 PST
Comment on attachment 182992 [details]
Patch

View in context: https://bugs.webkit.org/attachment.cgi?id=182992&action=review

> Source/WebCore/inspector/InjectedScriptCanvasModuleSource.js:-2957
> -        if (!this._traceLogPlayer || this._traceLogPlayer.traceLog() !== traceLog) {

Why did this code go?

> Source/WebCore/inspector/InjectedScriptCanvasModuleSource.js:-2994
> -    _onTraceLogPlayerReset: function()

ditto
Comment 3 Andrey Adaikin 2013-01-18 06:57:26 PST
Comment on attachment 182992 [details]
Patch

View in context: https://bugs.webkit.org/attachment.cgi?id=182992&action=review

>> Source/WebCore/inspector/InjectedScriptCanvasModuleSource.js:-2957
>> -        if (!this._traceLogPlayer || this._traceLogPlayer.traceLog() !== traceLog) {
> 
> Why did this code go?

Now these players are stored in the this._traceLogPlayers map, and we will support replaying all trace logs simultaneously (while before we kept only last player that was touched).
This change is needed because we will expose replayed resources state (like current screenshot of a canvas, and etc.), which are bound to a "replay world".

>> Source/WebCore/inspector/InjectedScriptCanvasModuleSource.js:-2994
>> -    _onTraceLogPlayerReset: function()
> 
> ditto

This is not needed any more, everything is encapsulated in the Player.
Comment 4 WebKit Review Bot 2013-01-18 07:13:43 PST
Comment on attachment 182992 [details]
Patch

Clearing flags on attachment: 182992

Committed r140142: <http://trac.webkit.org/changeset/140142>
Comment 5 WebKit Review Bot 2013-01-18 07:13:47 PST
All reviewed patches have been landed.  Closing bug.