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

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

Issue 337123002: Support counter graphs in Timeline based on trace events (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 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 * @extends {WebInspector.TimelineModel} 7 * @extends {WebInspector.TimelineModel}
8 * @param {!WebInspector.TimelineManager} timelineManager 8 * @param {!WebInspector.TimelineManager} timelineManager
9 */ 9 */
10 WebInspector.TimelineModelImpl = function(timelineManager) 10 WebInspector.TimelineModelImpl = function(timelineManager)
(...skipping 464 matching lines...) Expand 10 before | Expand all | Expand 10 after
475 * @return {string} 475 * @return {string}
476 */ 476 */
477 type: function() 477 type: function()
478 { 478 {
479 return this._record.type; 479 return this._record.type;
480 }, 480 },
481 481
482 /** 482 /**
483 * @return {?Object} 483 * @return {?Object}
484 */ 484 */
485 counters: function()
486 {
487 return this.type() === WebInspector.TimelineModel.RecordType.UpdateCount ers ? this.data() : null;
488 },
489
490 /**
491 * @return {?Object}
492 */
485 highlightQuad: function() 493 highlightQuad: function()
486 { 494 {
487 var quad = null; 495 var quad = null;
488 var recordTypes = WebInspector.TimelineModel.RecordType; 496 var recordTypes = WebInspector.TimelineModel.RecordType;
489 switch(this.type()) { 497 switch(this.type()) {
490 case recordTypes.Layout: 498 case recordTypes.Layout:
491 quad = this.data().root; 499 quad = this.data().root;
492 break; 500 break;
493 case recordTypes.Paint: 501 case recordTypes.Paint:
494 quad = this.data().clip; 502 quad = this.data().clip;
(...skipping 275 matching lines...) Expand 10 before | Expand all | Expand 10 after
770 break; 778 break;
771 length += itemLength; 779 length += itemLength;
772 data.push(item); 780 data.push(item);
773 ++this._recordIndex; 781 ++this._recordIndex;
774 } 782 }
775 if (this._recordIndex === this._payloads.length) 783 if (this._recordIndex === this._payloads.length)
776 data.push(data.pop() + "]"); 784 data.push(data.pop() + "]");
777 stream.write(data.join(separator), this._writeNextChunk.bind(this)); 785 stream.write(data.join(separator), this._writeNextChunk.bind(this));
778 } 786 }
779 } 787 }
OLDNEW
« no previous file with comments | « Source/devtools/front_end/timeline/TimelineModel.js ('k') | Source/devtools/front_end/timeline/TimelinePanel.js » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698