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

Unified Diff: third_party/WebKit/Source/devtools/front_end/sources/NavigatorView.js

Issue 2696143005: DevTools: fix NavigatorView exception (Closed)
Patch Set: move test to http Created 3 years, 10 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
« no previous file with comments | « third_party/WebKit/LayoutTests/http/tests/inspector/sources/navigator-view-content-scripts-expected.txt ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: third_party/WebKit/Source/devtools/front_end/sources/NavigatorView.js
diff --git a/third_party/WebKit/Source/devtools/front_end/sources/NavigatorView.js b/third_party/WebKit/Source/devtools/front_end/sources/NavigatorView.js
index 0a517f822077166fe0214e78cab82bd4d618f5cb..fc433ab3c6559eed4b487e099400bf424ef4ffdb 100644
--- a/third_party/WebKit/Source/devtools/front_end/sources/NavigatorView.js
+++ b/third_party/WebKit/Source/devtools/front_end/sources/NavigatorView.js
@@ -317,10 +317,6 @@ Sources.NavigatorView = class extends UI.VBox {
_projectRemoved(event) {
var project = /** @type {!Workspace.Project} */ (event.data);
- var frame = Bindings.NetworkProject.frameForProject(project);
- if (frame)
- this._discardFrame(frame);
-
var uiSourceCodes = project.uiSourceCodes();
for (var i = 0; i < uiSourceCodes.length; ++i)
this._removeUISourceCode(uiSourceCodes[i]);
@@ -548,8 +544,10 @@ Sources.NavigatorView = class extends UI.VBox {
break;
if (!(node instanceof Sources.NavigatorGroupTreeNode || node instanceof Sources.NavigatorFolderTreeNode))
break;
- if (node._type === Sources.NavigatorView.Types.Frame)
+ if (node._type === Sources.NavigatorView.Types.Frame) {
+ this._discardFrame(/** @type {!SDK.ResourceTreeFrame} */ (frame));
break;
+ }
var folderId = this._folderNodeId(project, target, frame, uiSourceCode.origin(), node._folderPath);
this._subfolderNodes.delete(folderId);
« no previous file with comments | « third_party/WebKit/LayoutTests/http/tests/inspector/sources/navigator-view-content-scripts-expected.txt ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698