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