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

Unified Diff: third_party/WebKit/Source/devtools/front_end/sdk/SubTargetsManager.js

Issue 2451363002: [DevTools] Move main target/connection to TargetManager. (Closed)
Patch Set: Created 4 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: third_party/WebKit/Source/devtools/front_end/sdk/SubTargetsManager.js
diff --git a/third_party/WebKit/Source/devtools/front_end/sdk/SubTargetsManager.js b/third_party/WebKit/Source/devtools/front_end/sdk/SubTargetsManager.js
index b0750a35c3a56ec8735a6f22f0e9e52b95a033cc..21cb315ff96ccd9fefd56ba7f8809b9c382de2cb 100644
--- a/third_party/WebKit/Source/devtools/front_end/sdk/SubTargetsManager.js
+++ b/third_party/WebKit/Source/devtools/front_end/sdk/SubTargetsManager.js
@@ -332,11 +332,11 @@ WebInspector.TargetInfo = function(payload)
this.id = payload.targetId;
this.url = payload.url;
this.type = payload.type;
- if (this.type !== "page" && this.type !== "iframe") {
- this.title = WebInspector.UIString("Worker: %s", this.url);
- this.canActivate = false;
- } else {
+ this.canActivate = this.type === "page" || this.type === "iframe";
+ if (this.type === "node")
+ this.title = WebInspector.UIString("Node: %s", this.url);
+ else if (this.type === "page" || this.type === "iframe")
this.title = payload.title;
- this.canActivate = true;
- }
+ else
+ this.title = WebInspector.UIString("Worker: %s", this.url);
};

Powered by Google App Engine
This is Rietveld 408576698