| Index: third_party/WebKit/Source/devtools/front_end/sdk/DebuggerModel.js
|
| diff --git a/third_party/WebKit/Source/devtools/front_end/sdk/DebuggerModel.js b/third_party/WebKit/Source/devtools/front_end/sdk/DebuggerModel.js
|
| index 45bf9ed1377780f64d391860aa04d41d25501496..98854514db235b85bb0e9dc5c084a4e69ce04ac0 100644
|
| --- a/third_party/WebKit/Source/devtools/front_end/sdk/DebuggerModel.js
|
| +++ b/third_party/WebKit/Source/devtools/front_end/sdk/DebuggerModel.js
|
| @@ -280,6 +280,31 @@ WebInspector.DebuggerModel = class extends WebInspector.SDKModel {
|
| }
|
|
|
| /**
|
| + * @param {!WebInspector.DebuggerModel.Location} startLocation
|
| + * @param {!WebInspector.DebuggerModel.Location} endLocation
|
| + * @return {!Promise<!Array<!WebInspector.DebuggerModel.Location>>}
|
| + */
|
| + getPossibleBreakpoints(startLocation, endLocation) {
|
| + var fulfill;
|
| + var promise = new Promise(resolve => fulfill = resolve);
|
| + this._agent.getPossibleBreakpoints(startLocation.payload(), endLocation.payload(), checkErrorAndReturn.bind(this));
|
| + return promise;
|
| +
|
| + /**
|
| + * @this {!WebInspector.DebuggerModel}
|
| + * @param {?Protocol.Error} error
|
| + * @param {?Array<!Protocol.Debugger.Location>} locations
|
| + */
|
| + function checkErrorAndReturn(error, locations) {
|
| + if (error || !locations) {
|
| + fulfill([]);
|
| + return;
|
| + }
|
| + fulfill(locations.map(location => WebInspector.DebuggerModel.Location.fromPayload(this, location)));
|
| + }
|
| + }
|
| +
|
| + /**
|
| * @param {!Protocol.Debugger.BreakpointId} breakpointId
|
| * @param {!Protocol.Debugger.Location} location
|
| */
|
|
|