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

Side by Side Diff: Source/devtools/front_end/timeline/TracingTimelineModel.js

Issue 397313003: DevTools: Remove target function from TimelineModel (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Rebase once more Created 6 years, 5 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 unified diff | Download patch | Annotate | Revision Log
OLDNEW
1 // Copyright 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 /** 5 /**
6 * @constructor 6 * @constructor
7 * @param {!WebInspector.TracingModel} tracingModel 7 * @param {!WebInspector.TracingModel} tracingModel
8 * @param {!WebInspector.TimelineModel.Filter} recordFilter 8 * @param {!WebInspector.TimelineModel.Filter} recordFilter
9 * @extends {WebInspector.TimelineModel} 9 * @extends {WebInspector.TimelineModel}
10 */ 10 */
11 WebInspector.TracingTimelineModel = function(tracingModel, recordFilter) 11 WebInspector.TracingTimelineModel = function(tracingModel, recordFilter)
12 { 12 {
13 WebInspector.TimelineModel.call(this, tracingModel.target()); 13 WebInspector.TimelineModel.call(this);
14 this._tracingModel = tracingModel; 14 this._tracingModel = tracingModel;
15 this._inspectedTargetEvents = []; 15 this._inspectedTargetEvents = [];
16 this._recordFilter = recordFilter; 16 this._recordFilter = recordFilter;
17 17
18 this.reset(); 18 this.reset();
19 } 19 }
20 20
21 WebInspector.TracingTimelineModel.RecordType = { 21 WebInspector.TracingTimelineModel.RecordType = {
22 Program: "Program", 22 Program: "Program",
23 EventDispatch: "EventDispatch", 23 EventDispatch: "EventDispatch",
(...skipping 579 matching lines...) Expand 10 before | Expand all | Expand 10 after
603 { 603 {
604 var initiator = this._event.initiator; 604 var initiator = this._event.initiator;
605 return initiator ? initiator._timelineRecord : null; 605 return initiator ? initiator._timelineRecord : null;
606 }, 606 },
607 607
608 /** 608 /**
609 * @return {!WebInspector.Target} 609 * @return {!WebInspector.Target}
610 */ 610 */
611 target: function() 611 target: function()
612 { 612 {
613 return this._model.target(); 613 //FIXME: get it from this._event
614 return WebInspector.targetManager.targets()[0];
614 }, 615 },
615 616
616 /** 617 /**
617 * @return {number} 618 * @return {number}
618 */ 619 */
619 selfTime: function() 620 selfTime: function()
620 { 621 {
621 return this._event.selfTime; 622 return this._event.selfTime;
622 }, 623 },
623 624
(...skipping 130 matching lines...) Expand 10 before | Expand all | Expand 10 after
754 }, 755 },
755 756
756 /** 757 /**
757 * @return {!WebInspector.TimelineModel} 758 * @return {!WebInspector.TimelineModel}
758 */ 759 */
759 timelineModel: function() 760 timelineModel: function()
760 { 761 {
761 return this._model; 762 return this._model;
762 } 763 }
763 } 764 }
OLDNEW
« no previous file with comments | « Source/devtools/front_end/timeline/TimelinePanel.js ('k') | Source/devtools/front_end/timeline/TracingTimelineUIUtils.js » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698