Bug 107019

Summary: Web Inspector: [Canvas] introduce Resource.toDataURL
Product: WebKit Reporter: Andrey Adaikin <aandrey>
Component: Web Inspector (Deprecated)Assignee: Andrey Adaikin <aandrey>
Status: RESOLVED FIXED    
Severity: Normal CC: apavlov, keishi, loislo, pfeldman, pmuellr, vsevik, web-inspector-bugs, webkit.review.bot, yurys
Priority: P2    
Version: 528+ (Nightly build)   
Hardware: All   
OS: All   
Bug Depends on:    
Bug Blocks: 107274    
Attachments:
Description Flags
Patch none

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.