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

Side by Side Diff: third_party/WebKit/Source/devtools/front_end/timeline/TimelinePanel.js

Issue 1791533003: DevTools: Do not invoke CPU throttling on worker targets. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 4 years, 9 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
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 /* 1 /*
2 * Copyright (C) 2012 Google Inc. All rights reserved. 2 * Copyright (C) 2012 Google Inc. All rights reserved.
3 * Copyright (C) 2012 Intel Inc. All rights reserved. 3 * Copyright (C) 2012 Intel Inc. All rights reserved.
4 * 4 *
5 * Redistribution and use in source and binary forms, with or without 5 * Redistribution and use in source and binary forms, with or without
6 * modification, are permitted provided that the following conditions are 6 * modification, are permitted provided that the following conditions are
7 * met: 7 * met:
8 * 8 *
9 * * Redistributions of source code must retain the above copyright 9 * * Redistributions of source code must retain the above copyright
10 * notice, this list of conditions and the following disclaimer. 10 * notice, this list of conditions and the following disclaimer.
(...skipping 2106 matching lines...) Expand 10 before | Expand all | Expand 10 after
2117 2117
2118 /** 2118 /**
2119 * @constructor 2119 * @constructor
2120 * @extends {WebInspector.Object} 2120 * @extends {WebInspector.Object}
2121 * @implements {WebInspector.TargetManager.Observer} 2121 * @implements {WebInspector.TargetManager.Observer}
2122 */ 2122 */
2123 WebInspector.CPUThrottlingManager = function() 2123 WebInspector.CPUThrottlingManager = function()
2124 { 2124 {
2125 this._targets = []; 2125 this._targets = [];
2126 this._throttlingRate = 1.; // No throttling 2126 this._throttlingRate = 1.; // No throttling
2127 WebInspector.targetManager.observeTargets(this); 2127 WebInspector.targetManager.observeTargets(this, WebInspector.Target.Type.Pag e);
2128 } 2128 }
2129 2129
2130 WebInspector.CPUThrottlingManager.prototype = { 2130 WebInspector.CPUThrottlingManager.prototype = {
2131 /** 2131 /**
2132 * @param {number} value 2132 * @param {number} value
2133 */ 2133 */
2134 setRate: function(value) 2134 setRate: function(value)
2135 { 2135 {
2136 this._throttlingRate = value; 2136 this._throttlingRate = value;
2137 this._targets.forEach(target => target.emulationAgent().setCPUThrottling Rate(value)); 2137 this._targets.forEach(target => target.emulationAgent().setCPUThrottling Rate(value));
(...skipping 21 matching lines...) Expand all
2159 * @override 2159 * @override
2160 * @param {!WebInspector.Target} target 2160 * @param {!WebInspector.Target} target
2161 */ 2161 */
2162 targetRemoved: function(target) 2162 targetRemoved: function(target)
2163 { 2163 {
2164 this._targets.remove(target, true); 2164 this._targets.remove(target, true);
2165 }, 2165 },
2166 2166
2167 __proto__: WebInspector.Object.prototype 2167 __proto__: WebInspector.Object.prototype
2168 } 2168 }
OLDNEW
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698