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

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

Issue 710113002: DevTools: remove TimelineModel.Events.RecordAdded event (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Created 6 years, 1 month 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/MemoryCountersGraph.js
diff --git a/Source/devtools/front_end/timeline/MemoryCountersGraph.js b/Source/devtools/front_end/timeline/MemoryCountersGraph.js
index 737e8ca7ffc3938ad165674f85e4cc8a83800fa5..8b14932ced7126c32c2e737261639dab3175e97a 100644
--- a/Source/devtools/front_end/timeline/MemoryCountersGraph.js
+++ b/Source/devtools/front_end/timeline/MemoryCountersGraph.js
@@ -61,10 +61,14 @@ WebInspector.MemoryCountersGraph.prototype = {
},
/**
- * @param {!WebInspector.TimelineModel.Record} record
+ * @override
+ * @param {?RegExp} textFilter
*/
- addRecord: function(record)
+ refreshRecords: function(textFilter)
{
+ this.reset();
+ var records = this._model.records();
+
/**
* @param {!WebInspector.TimelineModel.Record} record
* @this {!WebInspector.MemoryCountersGraph}
@@ -84,17 +88,9 @@ WebInspector.MemoryCountersGraph.prototype = {
if (this._gpuMemoryCounter && (gpuMemoryLimitCounterName in counters))
this._gpuMemoryCounter.setLimit(counters[gpuMemoryLimitCounterName]);
}
- WebInspector.TimelineModel.forAllRecords([record], null, addStatistics.bind(this));
+ WebInspector.TimelineModel.forAllRecords(records, null, addStatistics.bind(this));
this.scheduleRefresh();
},
- refreshRecords: function()
- {
- this.reset();
- var records = this._model.records();
- for (var i = 0; i < records.length; ++i)
- this.addRecord(records[i]);
- },
-
__proto__: WebInspector.CountersGraph.prototype
}

Powered by Google App Engine
This is Rietveld 408576698