| 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 1073 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1084 * @param {boolean} doNotPauseOnExceptionsAndMuteConsole | 1084 * @param {boolean} doNotPauseOnExceptionsAndMuteConsole |
| 1085 * @param {boolean} returnByValue | 1085 * @param {boolean} returnByValue |
| 1086 * @param {boolean} generatePreview | 1086 * @param {boolean} generatePreview |
| 1087 * @param {function(?RuntimeAgent.RemoteObject, boolean=, ?RuntimeAgent.Exce
ptionDetails=)} callback | 1087 * @param {function(?RuntimeAgent.RemoteObject, boolean=, ?RuntimeAgent.Exce
ptionDetails=)} callback |
| 1088 */ | 1088 */ |
| 1089 evaluate: function(code, objectGroup, includeCommandLineAPI, doNotPauseOnExc
eptionsAndMuteConsole, returnByValue, generatePreview, callback) | 1089 evaluate: function(code, objectGroup, includeCommandLineAPI, doNotPauseOnExc
eptionsAndMuteConsole, returnByValue, generatePreview, callback) |
| 1090 { | 1090 { |
| 1091 /** | 1091 /** |
| 1092 * @param {?Protocol.Error} error | 1092 * @param {?Protocol.Error} error |
| 1093 * @param {!RuntimeAgent.RemoteObject} result | 1093 * @param {!RuntimeAgent.RemoteObject} result |
| 1094 * @param {boolean=} wasThrown | 1094 * @param {!RuntimeAgent.ExceptionDetails=} exceptionDetails |
| 1095 * @param {?RuntimeAgent.ExceptionDetails=} exceptionDetails | |
| 1096 */ | 1095 */ |
| 1097 function didEvaluateOnCallFrame(error, result, wasThrown, exceptionDetai
ls) | 1096 function didEvaluateOnCallFrame(error, result, exceptionDetails) |
| 1098 { | 1097 { |
| 1099 if (error) { | 1098 if (error) { |
| 1100 console.error(error); | 1099 console.error(error); |
| 1101 callback(null, false); | 1100 callback(null, false); |
| 1102 return; | 1101 return; |
| 1103 } | 1102 } |
| 1104 callback(result, wasThrown, exceptionDetails); | 1103 callback(result, !!exceptionDetails, exceptionDetails); |
| 1105 } | 1104 } |
| 1106 this._debuggerAgent.evaluateOnCallFrame(this._payload.callFrameId, code,
objectGroup, includeCommandLineAPI, doNotPauseOnExceptionsAndMuteConsole, retur
nByValue, generatePreview, didEvaluateOnCallFrame); | 1105 this._debuggerAgent.evaluateOnCallFrame(this._payload.callFrameId, code,
objectGroup, includeCommandLineAPI, doNotPauseOnExceptionsAndMuteConsole, retur
nByValue, generatePreview, didEvaluateOnCallFrame); |
| 1107 }, | 1106 }, |
| 1108 | 1107 |
| 1109 /** | 1108 /** |
| 1110 * @param {function(?Protocol.Error=)=} callback | 1109 * @param {function(?Protocol.Error=)=} callback |
| 1111 */ | 1110 */ |
| 1112 restart: function(callback) | 1111 restart: function(callback) |
| 1113 { | 1112 { |
| 1114 /** | 1113 /** |
| (...skipping 176 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1291 /** | 1290 /** |
| 1292 * @param {?WebInspector.Target} target | 1291 * @param {?WebInspector.Target} target |
| 1293 * @return {?WebInspector.DebuggerModel} | 1292 * @return {?WebInspector.DebuggerModel} |
| 1294 */ | 1293 */ |
| 1295 WebInspector.DebuggerModel.fromTarget = function(target) | 1294 WebInspector.DebuggerModel.fromTarget = function(target) |
| 1296 { | 1295 { |
| 1297 if (!target || !target.hasJSCapability()) | 1296 if (!target || !target.hasJSCapability()) |
| 1298 return null; | 1297 return null; |
| 1299 return /** @type {?WebInspector.DebuggerModel} */ (target.model(WebInspector
.DebuggerModel)); | 1298 return /** @type {?WebInspector.DebuggerModel} */ (target.model(WebInspector
.DebuggerModel)); |
| 1300 } | 1299 } |
| OLD | NEW |