Index: third_party/WebKit/Source/devtools/front_end/bindings/NetworkProject.js |
diff --git a/third_party/WebKit/Source/devtools/front_end/bindings/NetworkProject.js b/third_party/WebKit/Source/devtools/front_end/bindings/NetworkProject.js |
index f1855ccffcb90080937efadeb08945a7af4aacc0..d78d0b3fd49b033af26aa20d64d45f8bc84877e1 100644 |
--- a/third_party/WebKit/Source/devtools/front_end/bindings/NetworkProject.js |
+++ b/third_party/WebKit/Source/devtools/front_end/bindings/NetworkProject.js |
@@ -61,14 +61,14 @@ Bindings.NetworkProjectManager = class { |
/** |
* @unrestricted |
*/ |
-Bindings.NetworkProject = class extends SDK.SDKObject { |
+Bindings.NetworkProject = class { |
/** |
* @param {!SDK.Target} target |
* @param {!Workspace.Workspace} workspace |
* @param {?SDK.ResourceTreeModel} resourceTreeModel |
*/ |
constructor(target, workspace, resourceTreeModel) { |
- super(target); |
+ this._target = target; |
pfeldman
2017/04/07 18:36:03
I don't think it makes sense removing SDKObject wi
|
this._workspace = workspace; |
/** @type {!Map<string, !Bindings.ContentProviderBasedProject>} */ |
this._workspaceProjects = new Map(); |
@@ -167,7 +167,7 @@ Bindings.NetworkProject = class extends SDK.SDKObject { |
* @return {!Bindings.ContentProviderBasedProject} |
*/ |
_workspaceProject(frameId, isContentScripts) { |
- var projectId = Bindings.NetworkProject.projectId(this.target(), frameId, isContentScripts); |
+ var projectId = Bindings.NetworkProject.projectId(this._target, frameId, isContentScripts); |
var projectType = isContentScripts ? Workspace.projectTypes.ContentScripts : Workspace.projectTypes.Network; |
var project = this._workspaceProjects.get(projectId); |
@@ -176,7 +176,7 @@ Bindings.NetworkProject = class extends SDK.SDKObject { |
project = new Bindings.ContentProviderBasedProject( |
this._workspace, projectId, projectType, '', false /* isServiceProject */); |
- project[Bindings.NetworkProject._targetSymbol] = this.target(); |
+ project[Bindings.NetworkProject._targetSymbol] = this._target; |
project[Bindings.NetworkProject._frameSymbol] = |
frameId && this._resourceTreeModel ? this._resourceTreeModel.frameForId(frameId) : null; |
this._workspaceProjects.set(projectId, project); |
@@ -213,7 +213,7 @@ Bindings.NetworkProject = class extends SDK.SDKObject { |
*/ |
_removeFileForURL(url, frameId, isContentScript) { |
var project = |
- this._workspaceProjects.get(Bindings.NetworkProject.projectId(this.target(), frameId, isContentScript)); |
+ this._workspaceProjects.get(Bindings.NetworkProject.projectId(this._target, frameId, isContentScript)); |
if (!project) |
return; |
project.removeFile(url); |
@@ -328,7 +328,7 @@ Bindings.NetworkProject = class extends SDK.SDKObject { |
return; |
// Never load document twice. |
- var projectId = Bindings.NetworkProject.projectId(this.target(), resource.frameId, false); |
+ var projectId = Bindings.NetworkProject.projectId(this._target, resource.frameId, false); |
var project = this._workspaceProjects.get(projectId); |
if (project && project.uiSourceCodeForURL(resource.url)) |
return; |
@@ -374,7 +374,7 @@ Bindings.NetworkProject = class extends SDK.SDKObject { |
} |
_suspendStateChanged() { |
- if (this.target().targetManager().allTargetsSuspended()) |
+ if (this._target.targetManager().allTargetsSuspended()) |
this._reset(); |
else |
this._populate(); |
@@ -390,7 +390,7 @@ Bindings.NetworkProject = class extends SDK.SDKObject { |
var url = contentProvider.contentURL(); |
var project = this._workspaceProject(frameId, isContentScript); |
var uiSourceCode = project.createUISourceCode(url, contentProvider.contentType()); |
- uiSourceCode[Bindings.NetworkProject._targetSymbol] = this.target(); |
+ uiSourceCode[Bindings.NetworkProject._targetSymbol] = this._target; |
return uiSourceCode; |
} |
@@ -407,7 +407,7 @@ Bindings.NetworkProject = class extends SDK.SDKObject { |
_dispose() { |
this._reset(); |
Common.EventTarget.removeEventListeners(this._eventListeners); |
- delete this.target()[Bindings.NetworkProject._networkProjectSymbol]; |
+ delete this._target[Bindings.NetworkProject._networkProjectSymbol]; |
} |
_reset() { |