OLD | NEW |
1 /* | 1 /* |
2 * Copyright (C) 2010 Google Inc. All rights reserved. | 2 * Copyright (C) 2010 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 252 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
263 | 263 |
264 var target = this.target(); | 264 var target = this.target(); |
265 /** | 265 /** |
266 * @param {?Protocol.Error} error | 266 * @param {?Protocol.Error} error |
267 * @param {!DebuggerAgent.BreakpointId} breakpointId | 267 * @param {!DebuggerAgent.BreakpointId} breakpointId |
268 * @param {!Array.<!DebuggerAgent.Location>} locations | 268 * @param {!Array.<!DebuggerAgent.Location>} locations |
269 */ | 269 */ |
270 function didSetBreakpoint(error, breakpointId, locations) | 270 function didSetBreakpoint(error, breakpointId, locations) |
271 { | 271 { |
272 if (callback) { | 272 if (callback) { |
273 var rawLocations = locations.map(WebInspector.DebuggerModel.Loca
tion.fromPayload.bind(WebInspector.DebuggerModel.Location, target)); | 273 var rawLocations = locations ? locations.map(WebInspector.Debugg
erModel.Location.fromPayload.bind(WebInspector.DebuggerModel.Location, target))
: []; |
274 callback(error ? null : breakpointId, rawLocations); | 274 callback(error ? null : breakpointId, rawLocations); |
275 } | 275 } |
276 } | 276 } |
277 this._agent.setBreakpointByUrl(lineNumber, url, undefined, columnNumber,
condition, undefined, didSetBreakpoint); | 277 this._agent.setBreakpointByUrl(lineNumber, url, undefined, columnNumber,
condition, undefined, didSetBreakpoint); |
278 WebInspector.userMetrics.ScriptsBreakpointSet.record(); | 278 WebInspector.userMetrics.ScriptsBreakpointSet.record(); |
279 }, | 279 }, |
280 | 280 |
281 /** | 281 /** |
282 * @param {!WebInspector.DebuggerModel.Location} rawLocation | 282 * @param {!WebInspector.DebuggerModel.Location} rawLocation |
283 * @param {string} condition | 283 * @param {string} condition |
(...skipping 837 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1121 this.asyncStackTrace.dispose(); | 1121 this.asyncStackTrace.dispose(); |
1122 }, | 1122 }, |
1123 | 1123 |
1124 __proto__: WebInspector.TargetAware.prototype | 1124 __proto__: WebInspector.TargetAware.prototype |
1125 } | 1125 } |
1126 | 1126 |
1127 /** | 1127 /** |
1128 * @type {!WebInspector.DebuggerModel} | 1128 * @type {!WebInspector.DebuggerModel} |
1129 */ | 1129 */ |
1130 WebInspector.debuggerModel; | 1130 WebInspector.debuggerModel; |
OLD | NEW |