Bug 135170

Summary: Web Inspector: show a replay dashboard when capturing or replaying
Product: WebKit Reporter: Brian Burg <burg>
Component: Web InspectorAssignee: Brian Burg <burg>
Status: RESOLVED FIXED    
Severity: Normal CC: graouts, joepeck, timothy, webkit-bug-importer
Priority: P2 Keywords: InRadar
Version: 528+ (Nightly build)   
Hardware: All   
OS: All   
Bug Depends on: 135130    
Bug Blocks: 135225    
Attachments:
Description Flags
Patch timothy: review+

Description Brian Burg 2014-07-22 13:14:32 PDT
Since replay is a system-wide property, the user should be able to see the system's replay status when it is relevant to the inspected web content. For example, the replay dashboard should be automatically shown when capturing or replaying starts.
Comment 1 Radar WebKit Bug Importer 2014-07-22 13:15:05 PDT
<rdar://problem/17767423>
Comment 2 Brian Burg 2014-07-22 16:02:54 PDT
Eventually I want to get some sort of mini-timeline ported to the new replay infrastructure (the one in trunk). There is also some more plumbing needed in the replay protocol domain so that recordings can be ejected and imported/exported from file.

My current WIP patch adds record/play/pause buttons that are correctly synced to events from the WebInspector.ReplayManager. Since this UI isn't visible by default, I could submit just this functionality and incrementally add the other pieces.

In any case, the UI will not be terribly useful until major replay blockers are landed in the next few months. Landing incrementally just reduces bitrot and branch drift.
Comment 3 Timothy Hatcher 2014-08-05 11:40:29 PDT
Missing patch? Looks like bug 135225 builds on this.
Comment 4 Brian Burg 2014-08-05 12:24:22 PDT
Created attachment 236043 [details]
Patch
Comment 5 Timothy Hatcher 2014-08-11 07:48:19 PDT
Comment on attachment 236043 [details]
Patch

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

> Source/WebInspectorUI/ChangeLog:20
> +        * UserInterface/Images/ReplayPauseButton.svg: Added.
> +        * UserInterface/Images/ReplayPlayButton.svg: Added.
> +        * UserInterface/Images/ReplayRecordingButton.svg: Added.

Once this lands I will take a look at making new icons for these to match 10.10.

> Source/WebInspectorUI/UserInterface/Views/ReplayDashboardView.js:62
> +    if (WebInspector.replayManager.sessionState === WebInspector.ReplayManager.SessionState.Capturing)
> +        this._captureStarted();
> +    else if (WebInspector.replayManager.sessionState === WebInspector.ReplayManager.SessionState.Inactive)
> +        this._captureStopped();
> +    // ReplayManager.sessionState must be Replaying.
> +    else if (WebInspector.replayManager.segmentState === WebInspector.ReplayManager.SegmentState.Dispatching)
> +        this._playbackStarted();
> +    // ReplayManager.sessionState must be Unloaded or Loaded, so execution is paused.
> +    else
> +        this._playbackPaused();

switch?
Comment 6 Brian Burg 2014-08-11 16:41:48 PDT
Committed r172420: <http://trac.webkit.org/changeset/172420>