| OLD | NEW |
| 1 /* | 1 /* |
| 2 * Copyright (C) 2011 Google Inc. All rights reserved. | 2 * Copyright (C) 2011 Google Inc. All rights reserved. |
| 3 * | 3 * |
| 4 * Redistribution and use in source and binary forms, with or without | 4 * Redistribution and use in source and binary forms, with or without |
| 5 * modification, are permitted provided that the following conditions are | 5 * modification, are permitted provided that the following conditions are |
| 6 * met: | 6 * met: |
| 7 * | 7 * |
| 8 * * Redistributions of source code must retain the above copyright | 8 * * Redistributions of source code must retain the above copyright |
| 9 * notice, this list of conditions and the following disclaimer. | 9 * notice, this list of conditions and the following disclaimer. |
| 10 * * Redistributions in binary form must reproduce the above | 10 * * Redistributions in binary form must reproduce the above |
| (...skipping 260 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 271 return Promise.resolve([]); | 271 return Promise.resolve([]); |
| 272 for (var debuggerModel of debuggerModels) { | 272 for (var debuggerModel of debuggerModels) { |
| 273 var startLocation = this._debuggerWorkspaceBinding.uiLocationToRawLocation
( | 273 var startLocation = this._debuggerWorkspaceBinding.uiLocationToRawLocation
( |
| 274 debuggerModel, uiSourceCode, textRange.startLine, textRange.startColum
n); | 274 debuggerModel, uiSourceCode, textRange.startLine, textRange.startColum
n); |
| 275 if (!startLocation) | 275 if (!startLocation) |
| 276 continue; | 276 continue; |
| 277 var endLocation = this._debuggerWorkspaceBinding.uiLocationToRawLocation( | 277 var endLocation = this._debuggerWorkspaceBinding.uiLocationToRawLocation( |
| 278 debuggerModel, uiSourceCode, textRange.endLine, textRange.endColumn); | 278 debuggerModel, uiSourceCode, textRange.endLine, textRange.endColumn); |
| 279 if (!endLocation) | 279 if (!endLocation) |
| 280 continue; | 280 continue; |
| 281 return debuggerModel.getPossibleBreakpoints(startLocation, endLocation).th
en(toUILocations.bind(this)); | 281 return debuggerModel.getPossibleBreakpoints(startLocation, endLocation, /*
restrictToFunction */ false) |
| 282 .then(toUILocations.bind(this)); |
| 282 } | 283 } |
| 283 return Promise.resolve([]); | 284 return Promise.resolve([]); |
| 284 | 285 |
| 285 /** | 286 /** |
| 286 * @this {!Bindings.BreakpointManager} | 287 * @this {!Bindings.BreakpointManager} |
| 287 * @param {!Array<!SDK.DebuggerModel.Location>} locations | 288 * @param {!Array<!SDK.DebuggerModel.Location>} locations |
| 288 * @return {!Array<!Workspace.UILocation>} | 289 * @return {!Array<!Workspace.UILocation>} |
| 289 */ | 290 */ |
| 290 function toUILocations(locations) { | 291 function toUILocations(locations) { |
| 291 var sortedLocations = locations.map(location => this._debuggerWorkspaceBin
ding.rawLocationToUILocation(location)); | 292 var sortedLocations = locations.map(location => this._debuggerWorkspaceBin
ding.rawLocationToUILocation(location)); |
| (...skipping 795 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1087 this.url = breakpoint._url; | 1088 this.url = breakpoint._url; |
| 1088 this.lineNumber = breakpoint.lineNumber(); | 1089 this.lineNumber = breakpoint.lineNumber(); |
| 1089 this.columnNumber = breakpoint.columnNumber(); | 1090 this.columnNumber = breakpoint.columnNumber(); |
| 1090 this.condition = breakpoint.condition(); | 1091 this.condition = breakpoint.condition(); |
| 1091 this.enabled = breakpoint.enabled(); | 1092 this.enabled = breakpoint.enabled(); |
| 1092 } | 1093 } |
| 1093 }; | 1094 }; |
| 1094 | 1095 |
| 1095 /** @type {!Bindings.BreakpointManager} */ | 1096 /** @type {!Bindings.BreakpointManager} */ |
| 1096 Bindings.breakpointManager; | 1097 Bindings.breakpointManager; |
| OLD | NEW |