| OLD | NEW |
| 1 // Copyright 2017 The Chromium Authors. All rights reserved. | 1 // Copyright 2017 The Chromium Authors. All rights reserved. |
| 2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
| 4 | 4 |
| 5 Resources.ResourcesSection = class { | 5 Resources.ResourcesSection = class { |
| 6 /** | 6 /** |
| 7 * @param {!Resources.ResourcesPanel} storagePanel | 7 * @param {!Resources.ResourcesPanel} storagePanel |
| 8 * @param {!UI.TreeElement} treeElement | 8 * @param {!UI.TreeElement} treeElement |
| 9 */ | 9 */ |
| 10 constructor(storagePanel, treeElement) { | 10 constructor(storagePanel, treeElement) { |
| (...skipping 57 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 68 | 68 |
| 69 this._treeElementForFrameId.remove(frame.id); | 69 this._treeElementForFrameId.remove(frame.id); |
| 70 if (frameTreeElement.parent) | 70 if (frameTreeElement.parent) |
| 71 frameTreeElement.parent.removeChild(frameTreeElement); | 71 frameTreeElement.parent.removeChild(frameTreeElement); |
| 72 } | 72 } |
| 73 | 73 |
| 74 /** | 74 /** |
| 75 * @param {!SDK.ResourceTreeFrame} frame | 75 * @param {!SDK.ResourceTreeFrame} frame |
| 76 */ | 76 */ |
| 77 _frameNavigated(frame) { | 77 _frameNavigated(frame) { |
| 78 if (!Resources.ResourcesSection._getParentFrame(frame)) | |
| 79 return; | |
| 80 var frameTreeElement = this._treeElementForFrameId.get(frame.id); | 78 var frameTreeElement = this._treeElementForFrameId.get(frame.id); |
| 81 if (frameTreeElement) | 79 if (frameTreeElement) |
| 82 frameTreeElement.frameNavigated(frame); | 80 frameTreeElement.frameNavigated(frame); |
| 83 } | 81 } |
| 84 | 82 |
| 85 /** | 83 /** |
| 86 * @param {!SDK.Resource} resource | 84 * @param {!SDK.Resource} resource |
| 87 */ | 85 */ |
| 88 _resourceAdded(resource) { | 86 _resourceAdded(resource) { |
| 89 var statusCode = resource['statusCode']; | 87 var statusCode = resource['statusCode']; |
| (...skipping 255 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 345 _sourceView() { | 343 _sourceView() { |
| 346 if (!this._sourceFrame) { | 344 if (!this._sourceFrame) { |
| 347 this._sourceFrame = new SourceFrame.ResourceSourceFrame(this._resource); | 345 this._sourceFrame = new SourceFrame.ResourceSourceFrame(this._resource); |
| 348 this._sourceFrame.setHighlighterType(this._resource.canonicalMimeType()); | 346 this._sourceFrame.setHighlighterType(this._resource.canonicalMimeType()); |
| 349 } | 347 } |
| 350 return this._sourceFrame; | 348 return this._sourceFrame; |
| 351 } | 349 } |
| 352 }; | 350 }; |
| 353 | 351 |
| 354 Resources.FrameResourceTreeElement._symbol = Symbol('treeElement'); | 352 Resources.FrameResourceTreeElement._symbol = Symbol('treeElement'); |
| OLD | NEW |