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

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

Issue 881263002: DevTools: use target-based model accessors only. (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Created 5 years, 11 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/TimelinePowerGraph.js
diff --git a/Source/devtools/front_end/timeline/TimelinePowerGraph.js b/Source/devtools/front_end/timeline/TimelinePowerGraph.js
index 1e211a40d72e65f8406a210828e93baab6f813d9..dc22835c2ac7c17e437694c37dd66ac1d90f56f9 100644
--- a/Source/devtools/front_end/timeline/TimelinePowerGraph.js
+++ b/Source/devtools/front_end/timeline/TimelinePowerGraph.js
@@ -14,7 +14,7 @@ WebInspector.TimelinePowerGraph = function(delegate, model)
WebInspector.CountersGraph.call(this, WebInspector.UIString("POWER"), delegate, model);
this._counter = this.createCounter(WebInspector.UIString("Power"), WebInspector.UIString("Power: %.2f\u2009watts"), "#d00");
- WebInspector.powerProfiler.addEventListener(WebInspector.PowerProfiler.EventTypes.PowerEventRecorded, this._onRecordAdded, this);
+ this.target().powerProfiler.addEventListener(WebInspector.PowerProfiler.EventTypes.PowerEventRecorded, this._onRecordAdded, this);
}
WebInspector.TimelinePowerGraph.prototype = {
@@ -24,7 +24,7 @@ WebInspector.TimelinePowerGraph.prototype = {
dispose: function()
{
WebInspector.CountersGraph.prototype.dispose.call(this);
- WebInspector.powerProfiler.removeEventListener(WebInspector.PowerProfiler.EventTypes.PowerEventRecorded, this._onRecordAdded, this);
+ this.target().powerProfiler.removeEventListener(WebInspector.PowerProfiler.EventTypes.PowerEventRecorded, this._onRecordAdded, this);
},
_onRecordAdded: function(event)
« no previous file with comments | « Source/devtools/front_end/timeline/TimelinePanel.js ('k') | Source/devtools/front_end/timeline/TimelinePowerOverview.js » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698