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

Unified Diff: Source/devtools/front_end/screencast/ScreencastView.js

Issue 614323003: DevTools: enable by default disableAgentsWhenProfile experiment (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: unnecessary line was removed Created 6 years, 2 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/screencast/ScreencastView.js
diff --git a/Source/devtools/front_end/screencast/ScreencastView.js b/Source/devtools/front_end/screencast/ScreencastView.js
index d8a8010e27da43b29775a0f5b63577b8bf5e469b..62b57d571ab687d8e1dc93a56d7aa310986f94b6 100644
--- a/Source/devtools/front_end/screencast/ScreencastView.js
+++ b/Source/devtools/front_end/screencast/ScreencastView.js
@@ -95,7 +95,7 @@ WebInspector.ScreencastView.prototype = {
WebInspector.resourceTreeModel.addEventListener(WebInspector.ResourceTreeModel.EventTypes.ScreencastFrame, this._screencastFrame, this);
WebInspector.resourceTreeModel.addEventListener(WebInspector.ResourceTreeModel.EventTypes.ScreencastVisibilityChanged, this._screencastVisibilityChanged, this);
- WebInspector.profilingLock().addEventListener(WebInspector.Lock.Events.StateChanged, this._onProfilingStateChange, this);
+ WebInspector.targetManager.addEventListener(WebInspector.TargetManager.Events.SuspendStateChanged, this._onSuspendStateChange, this);
this._updateGlasspane();
},
@@ -111,7 +111,7 @@ WebInspector.ScreencastView.prototype = {
_startCasting: function()
{
- if (WebInspector.profilingLock().isAcquired())
+ if (WebInspector.targetManager.allTargetsSuspended())
return;
if (this._isCasting)
return;
@@ -185,9 +185,9 @@ WebInspector.ScreencastView.prototype = {
/**
* @param {!WebInspector.Event} event
*/
- _onProfilingStateChange: function(event)
+ _onSuspendStateChange: function(event)
{
- if (WebInspector.profilingLock().isAcquired())
+ if (WebInspector.targetManager.allTargetsSuspended())
this._stopCasting();
else
this._startCasting();
@@ -199,7 +199,7 @@ WebInspector.ScreencastView.prototype = {
if (this._targetInactive) {
this._glassPaneElement.textContent = WebInspector.UIString("The tab is inactive");
this._glassPaneElement.classList.remove("hidden");
- } else if (WebInspector.profilingLock().isAcquired()) {
+ } else if (WebInspector.targetManager.allTargetsSuspended()) {
this._glassPaneElement.textContent = WebInspector.UIString("Profiling in progress");
this._glassPaneElement.classList.remove("hidden");
} else {

Powered by Google App Engine
This is Rietveld 408576698