Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(1813)

Unified Diff: Source/devtools/front_end/timeline/TimelinePanel.js

Issue 311113002: Move inspected target events calculation into TracingTimelineModel (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Created 6 years, 6 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: Source/devtools/front_end/timeline/TimelinePanel.js
diff --git a/Source/devtools/front_end/timeline/TimelinePanel.js b/Source/devtools/front_end/timeline/TimelinePanel.js
index a4f8ce2f1194b95e8a893f76546180697882abdb..aa11868a5a5b55c8f61397db47b70c7a522feb44 100644
--- a/Source/devtools/front_end/timeline/TimelinePanel.js
+++ b/Source/devtools/front_end/timeline/TimelinePanel.js
@@ -250,7 +250,7 @@ WebInspector.TimelinePanel.prototype = {
if (!this._lazyFrameModel) {
this._lazyFrameModel = new WebInspector.TimelineFrameModel(this._model);
if (this._lazyTracingModel)
- this._lazyFrameModel.addTraceEvents(this._lazyTracingModel.inspectedTargetEvents(), this._lazyTracingModel.sessionId());
+ this._lazyFrameModel.addTraceEvents(this._tracingTimelineModel.inspectedTargetEvents(), this._lazyTracingModel.sessionId());
}
return this._lazyFrameModel;
@@ -662,10 +662,13 @@ WebInspector.TimelinePanel.prototype = {
categories.push("disabled-by-default-devtools.timeline.stack");
this._model.willStartRecordingTraceEvents();
this._tracingModel().start(categories.join(","), "");
+ this._tracingTimelineModel.willStartRecordingTraceEvents();
} else {
this._model.startRecording(this._captureStacksSetting.get(), this._captureMemorySetting.get());
- if (WebInspector.experimentsSettings.timelineTracingMode.isEnabled())
+ if (WebInspector.experimentsSettings.timelineTracingMode.isEnabled()) {
this._tracingModel().start(WebInspector.TimelinePanel.defaultTracingCategoryFilter, "");
+ this._tracingTimelineModel.willStartRecordingTraceEvents();
+ }
}
for (var i = 0; i < this._overviewControls.length; ++i)
this._overviewControls[i].timelineStarted();
@@ -687,15 +690,14 @@ WebInspector.TimelinePanel.prototype = {
_onTracingComplete: function()
{
+ this._tracingTimelineModel.didStopRecordingTraceEvents();
if (this._lazyFrameModel) {
this._lazyFrameModel.reset();
- this._lazyFrameModel.addTraceEvents(this._lazyTracingModel.inspectedTargetEvents(), this._lazyTracingModel.sessionId());
+ this._lazyFrameModel.addTraceEvents(this._tracingTimelineModel.inspectedTargetEvents(), this._lazyTracingModel.sessionId());
this._overviewPane.update();
}
- if (WebInspector.experimentsSettings.timelineOnTraceEvents.isEnabled()) {
- this._tracingTimelineModel.didStopRecordingTraceEvents();
+ if (WebInspector.experimentsSettings.timelineOnTraceEvents.isEnabled())
this._model.didStopRecordingTraceEvents(this._tracingTimelineModel.mainThreadEvents());
- }
this._refreshViews();
},

Powered by Google App Engine
This is Rietveld 408576698