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

Unified Diff: third_party/WebKit/Source/devtools/front_end/components/DOMBreakpointsSidebarPane.js

Issue 2277543002: DevTools: Simplify DOMBreakpointsSidebarPane inspected URL (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Minor refactor Created 4 years, 4 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 | « no previous file | third_party/WebKit/Source/devtools/front_end/elements/ElementsPanel.js » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: third_party/WebKit/Source/devtools/front_end/components/DOMBreakpointsSidebarPane.js
diff --git a/third_party/WebKit/Source/devtools/front_end/components/DOMBreakpointsSidebarPane.js b/third_party/WebKit/Source/devtools/front_end/components/DOMBreakpointsSidebarPane.js
index fe4246383828943b93ef1a2347834d3ed0f61e9d..a6042c612a6fb4e8c3743859aa0c7a9aacc294f5 100644
--- a/third_party/WebKit/Source/devtools/front_end/components/DOMBreakpointsSidebarPane.js
+++ b/third_party/WebKit/Source/devtools/front_end/components/DOMBreakpointsSidebarPane.js
@@ -57,21 +57,12 @@ WebInspector.DOMBreakpointsSidebarPane = function()
this._contextMenuLabels[this._breakpointTypes.NodeRemoved] = WebInspector.UIString.capitalize("Node ^removal");
WebInspector.targetManager.addModelListener(WebInspector.DOMModel, WebInspector.DOMModel.Events.NodeRemoved, this._nodeRemoved, this);
- WebInspector.targetManager.addEventListener(WebInspector.TargetManager.Events.InspectedURLChanged, this._inspectedURLChanged, this);
- this._inspectedURL = WebInspector.targetManager.inspectedURL();
this._update();
}
WebInspector.DOMBreakpointsSidebarPane.Marker = "breakpoint-marker";
WebInspector.DOMBreakpointsSidebarPane.prototype = {
- _inspectedURLChanged: function()
- {
- this._breakpointElements = {};
- this.reset();
- this._inspectedURL = WebInspector.targetManager.inspectedURL();
- },
-
/**
* @param {!WebInspector.DOMNode} node
* @param {!WebInspector.ContextMenu} contextMenu
@@ -375,10 +366,14 @@ WebInspector.DOMBreakpointsSidebarPane.prototype = {
},
/**
- * @param {!WebInspector.DOMModel} domModel
+ * @param {!WebInspector.DOMDocument} domDocument
*/
- restoreBreakpoints: function(domModel)
+ restoreBreakpoints: function(domDocument)
{
+ this._breakpointElements = {};
+ this.reset();
+ this._inspectedURL = domDocument.documentURL;
+ var domModel = domDocument.domModel();
var pathToBreakpoints = {};
/**
« no previous file with comments | « no previous file | third_party/WebKit/Source/devtools/front_end/elements/ElementsPanel.js » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698