Chromium Code Reviews| Index: third_party/WebKit/Source/devtools/front_end/bindings/BreakpointManager.js |
| 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 88df8c07de7cbb1c99df450002bbcead19cc7d72..7291aebf9f8a3d2a0de31c7a92a3bfec58b1a683 100644 |
| --- a/third_party/WebKit/Source/devtools/front_end/bindings/BreakpointManager.js |
| +++ b/third_party/WebKit/Source/devtools/front_end/bindings/BreakpointManager.js |
| @@ -266,10 +266,10 @@ Bindings.BreakpointManager = class extends Common.Object { |
| * @return {!Promise<!Array<!Workspace.UILocation>>} |
| */ |
| possibleBreakpoints(uiSourceCode, textRange) { |
| - var startLocation = Bindings.debuggerWorkspaceBinding.uiLocationToRawLocation( |
| - uiSourceCode, textRange.startLine, textRange.startColumn); |
| - var endLocation = |
| - Bindings.debuggerWorkspaceBinding.uiLocationToRawLocation(uiSourceCode, textRange.endLine, textRange.endColumn); |
| + var startLocation = Bindings.debuggerWorkspaceBinding.uiLocationToRawLocations( |
| + uiSourceCode, textRange.startLine, textRange.startColumn)[0]; |
|
dgozman
2017/05/02 19:47:41
This is suspicious. What if there are multiple and
|
| + var endLocation = Bindings.debuggerWorkspaceBinding.uiLocationToRawLocations( |
| + uiSourceCode, textRange.endLine, textRange.endColumn)[0]; |
| if (!startLocation || !endLocation || startLocation.debuggerModel !== endLocation.debuggerModel) |
| return Promise.resolve([]); |
| @@ -809,7 +809,7 @@ Bindings.BreakpointManager.ModelBreakpoint = class { |
| var condition = this._breakpoint.condition(); |
| var debuggerLocation = uiSourceCode && |
| - Bindings.debuggerWorkspaceBinding.uiLocationToRawLocation(uiSourceCode, lineNumber, columnNumber); |
| + Bindings.debuggerWorkspaceBinding.uiLocationToRawLocations(uiSourceCode, lineNumber, columnNumber)[0]; |
| var newState; |
| if (this._breakpoint._isRemoved || !this._breakpoint.enabled() || this._scriptDiverged()) { |
| newState = null; |