WebKit Bugzilla
Attachment 356434 Details for
Bug 192248
: Web Inspector: REGRESSION(r238330): Timeline auto-capture does not work after page transition
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Requests
|
Help
|
New Account
|
Log In
Remember
[x]
|
Forgot Password
Login:
[x]
[patch]
[PATCH] Proposed Fix
better-1.patch (text/plain), 3.74 KB, created by
Joseph Pecoraro
on 2018-12-03 16:43:49 PST
(
hide
)
Description:
[PATCH] Proposed Fix
Filename:
MIME Type:
Creator:
Joseph Pecoraro
Created:
2018-12-03 16:43:49 PST
Size:
3.74 KB
patch
obsolete
>diff --git a/Source/WebInspectorUI/ChangeLog b/Source/WebInspectorUI/ChangeLog >index 55e1def1224..7d821964925 100644 >--- a/Source/WebInspectorUI/ChangeLog >+++ b/Source/WebInspectorUI/ChangeLog >@@ -1,3 +1,22 @@ >+2018-11-30 Joseph Pecoraro <pecoraro@apple.com> >+ >+ Web Inspector: REGRESSION(r238330): Timeline auto-capture does not work after page transition >+ https://bugs.webkit.org/show_bug.cgi?id=192248 >+ <rdar://problem/46390199> >+ >+ Reviewed by NOBODY (OOPS!). >+ >+ * UserInterface/Base/Main.js: >+ (WI.transitionPageTarget): >+ Let the TimelineManager perform work on page transitions. >+ >+ * UserInterface/Controllers/TimelineManager.js: >+ (WI.TimelineManager.prototype.initializeTarget): >+ Initialize the autocapture state of the target. >+ >+ (WI.TimelineManager.prototype.transitionPageTarget): >+ When transitioning pages perform a legacy (frontend based) timeline capture. >+ > 2018-11-30 Nikita Vasilyev <nvasilyev@apple.com> > > Web Inspector: Jumping from Computed to Styles should select property >diff --git a/Source/WebInspectorUI/UserInterface/Base/Main.js b/Source/WebInspectorUI/UserInterface/Base/Main.js >index 39dd620afd1..b10fc910470 100644 >--- a/Source/WebInspectorUI/UserInterface/Base/Main.js >+++ b/Source/WebInspectorUI/UserInterface/Base/Main.js >@@ -214,6 +214,7 @@ WI.transitionPageTarget = function(target) > this.notifications.dispatchEventToListeners(WI.Notification.TransitionPageTarget); > WI.domManager.transitionPageTarget(); > WI.networkManager.transitionPageTarget(); >+ WI.timelineManager.transitionPageTarget(); > }; > > WI.terminatePageTarget = function(target) >diff --git a/Source/WebInspectorUI/UserInterface/Controllers/TimelineManager.js b/Source/WebInspectorUI/UserInterface/Controllers/TimelineManager.js >index 4414e731d2e..a9867aabbd4 100644 >--- a/Source/WebInspectorUI/UserInterface/Controllers/TimelineManager.js >+++ b/Source/WebInspectorUI/UserInterface/Controllers/TimelineManager.js >@@ -49,6 +49,7 @@ WI.TimelineManager = class TimelineManager extends WI.Object > this._autoCaptureOnPageLoad = false; > this._mainResourceForAutoCapturing = null; > this._shouldSetAutoCapturingMainResource = false; >+ this._transitioningPageTarget = false; > this._boundStopCapturing = this.stopCapturing.bind(this); > > this._webTimelineScriptRecordsExpectingScriptProfilerEvents = null; >@@ -65,7 +66,18 @@ WI.TimelineManager = class TimelineManager extends WI.Object > > initializeTarget(target) > { >- this._updateAutoCaptureInstruments([target]); >+ if (target.TimelineAgent) { >+ this._updateAutoCaptureInstruments([target]); >+ >+ // COMPATIBILITY (iOS 9): Timeline.setAutoCaptureEnabled did not exist. >+ if (target.TimelineAgent.setAutoCaptureEnabled) >+ target.TimelineAgent.setAutoCaptureEnabled(this._autoCaptureOnPageLoad); >+ } >+ } >+ >+ transitionPageTarget() >+ { >+ this._transitioningPageTarget = true; > } > > // Static >@@ -830,6 +842,17 @@ WI.TimelineManager = class TimelineManager extends WI.Object > return; > > let frame = event.target; >+ >+ // When performing a page transition start a recording once the main resource changes. >+ // We start a legacy capture because the backend wasn't available to automatically >+ // initiate the capture, so the frontend must start the capture. >+ if (this._transitioningPageTarget) { >+ this._transitioningPageTarget = false; >+ if (this._autoCaptureOnPageLoad) >+ this._legacyAttemptStartAutoCapturingForFrame(frame); >+ return; >+ } >+ > if (this._attemptAutoCapturingForFrame(frame)) > return; >
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Flags:
hi
:
review+
ews-watchlist
:
commit-queue-
Actions:
View
|
Formatted Diff
|
Diff
Attachments on
bug 192248
:
356273
| 356434 |
356488