diff options
author | kozyatinskiy <kozyatinskiy@chromium.org> | 2016-03-25 16:08:17 -0700 |
---|---|---|
committer | Commit bot <commit-bot@chromium.org> | 2016-03-25 23:09:30 +0000 |
commit | c5e228cabf7876c6f65da715a9b5bf9507a8b12b (patch) | |
tree | 851896dfa09dec606330de6262c0258aa9486a59 /third_party/WebKit/Source/devtools/front_end/bindings/BreakpointManager.js | |
parent | b6d78f039a327f70412ccdb2c03a341c7f1fc8af (diff) | |
download | chromium_src-c5e228cabf7876c6f65da715a9b5bf9507a8b12b.zip chromium_src-c5e228cabf7876c6f65da715a9b5bf9507a8b12b.tar.gz chromium_src-c5e228cabf7876c6f65da715a9b5bf9507a8b12b.tar.bz2 |
[DevTools] Introduced WebInspector.LiveLocationPool
R=dgozman@chromium.org,pfeldman@chromium.org
Review URL: https://codereview.chromium.org/1818533003
Cr-Commit-Position: refs/heads/master@{#383396}
Diffstat (limited to 'third_party/WebKit/Source/devtools/front_end/bindings/BreakpointManager.js')
-rw-r--r-- | third_party/WebKit/Source/devtools/front_end/bindings/BreakpointManager.js | 10 |
1 files changed, 3 insertions, 7 deletions
diff --git a/third_party/WebKit/Source/devtools/front_end/bindings/BreakpointManager.js b/third_party/WebKit/Source/devtools/front_end/bindings/BreakpointManager.js index 53446c5..8671524 100644 --- a/third_party/WebKit/Source/devtools/front_end/bindings/BreakpointManager.js +++ b/third_party/WebKit/Source/devtools/front_end/bindings/BreakpointManager.js @@ -739,8 +739,7 @@ WebInspector.BreakpointManager.TargetBreakpoint = function(debuggerModel, breakp this._networkMapping = networkMapping; this._debuggerWorkspaceBinding = debuggerWorkspaceBinding; - /** @type {!Array.<!WebInspector.DebuggerWorkspaceBinding.Location>} */ - this._liveLocations = []; + this._liveLocations = new WebInspector.LiveLocationPool(); /** @type {!Object.<string, !WebInspector.UILocation>} */ this._uiLocations = {}; @@ -763,10 +762,7 @@ WebInspector.BreakpointManager.TargetBreakpoint.prototype = { this._breakpoint._removeUILocation(uiLocations[i]); this._uiLocations = {}; - - for (var i = 0; i < this._liveLocations.length; ++i) - this._liveLocations[i].dispose(); - this._liveLocations = []; + this._liveLocations.disposeAll(); }, _scheduleUpdateInDebugger: function() @@ -944,7 +940,7 @@ WebInspector.BreakpointManager.TargetBreakpoint.prototype = { this._breakpoint.remove(); return false; } - this._liveLocations.push(this._debuggerWorkspaceBinding.createLiveLocation(location, this._locationUpdated.bind(this, location))); + this._debuggerWorkspaceBinding.createLiveLocation(location, this._locationUpdated.bind(this, location), this._liveLocations); return true; }, |