| 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 302 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 313 function innerCallback(error) | 313 function innerCallback(error) |
| 314 { | 314 { |
| 315 if (error) | 315 if (error) |
| 316 console.error("Failed to remove breakpoint: " + error); | 316 console.error("Failed to remove breakpoint: " + error); |
| 317 if (callback) | 317 if (callback) |
| 318 callback(); | 318 callback(); |
| 319 } | 319 } |
| 320 }, | 320 }, |
| 321 | 321 |
| 322 /** | 322 /** |
| 323 * @param {string} objectId | |
| 324 * @param {function(?Array.<!DebuggerAgent.CollectionEntry>)} callback | |
| 325 */ | |
| 326 getCollectionEntries: function(objectId, callback) | |
| 327 { | |
| 328 this._agent.getCollectionEntries(objectId, innerCallback); | |
| 329 | |
| 330 /** | |
| 331 * @param {?Protocol.Error} error | |
| 332 * @param {?Array.<!DebuggerAgent.CollectionEntry>} response | |
| 333 */ | |
| 334 function innerCallback(error, response) | |
| 335 { | |
| 336 if (error) { | |
| 337 console.error(error); | |
| 338 callback(null); | |
| 339 return; | |
| 340 } | |
| 341 callback(response); | |
| 342 } | |
| 343 }, | |
| 344 | |
| 345 /** | |
| 346 * @param {!DebuggerAgent.BreakpointId} breakpointId | 323 * @param {!DebuggerAgent.BreakpointId} breakpointId |
| 347 * @param {!DebuggerAgent.Location} location | 324 * @param {!DebuggerAgent.Location} location |
| 348 */ | 325 */ |
| 349 _breakpointResolved: function(breakpointId, location) | 326 _breakpointResolved: function(breakpointId, location) |
| 350 { | 327 { |
| 351 this._breakpointResolvedEventTarget.dispatchEventToListeners(breakpointI
d, WebInspector.DebuggerModel.Location.fromPayload(this, location)); | 328 this._breakpointResolvedEventTarget.dispatchEventToListeners(breakpointI
d, WebInspector.DebuggerModel.Location.fromPayload(this, location)); |
| 352 }, | 329 }, |
| 353 | 330 |
| 354 globalObjectCleared: function() | 331 globalObjectCleared: function() |
| 355 { | 332 { |
| (...skipping 989 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1345 /** | 1322 /** |
| 1346 * @param {?WebInspector.Target} target | 1323 * @param {?WebInspector.Target} target |
| 1347 * @return {?WebInspector.DebuggerModel} | 1324 * @return {?WebInspector.DebuggerModel} |
| 1348 */ | 1325 */ |
| 1349 WebInspector.DebuggerModel.fromTarget = function(target) | 1326 WebInspector.DebuggerModel.fromTarget = function(target) |
| 1350 { | 1327 { |
| 1351 if (!target || !target.hasJSContext()) | 1328 if (!target || !target.hasJSContext()) |
| 1352 return null; | 1329 return null; |
| 1353 return /** @type {?WebInspector.DebuggerModel} */ (target.model(WebInspector
.DebuggerModel)); | 1330 return /** @type {?WebInspector.DebuggerModel} */ (target.model(WebInspector
.DebuggerModel)); |
| 1354 } | 1331 } |
| OLD | NEW |