OLD | NEW |
1 /* | 1 /* |
2 * Copyright (C) 2008 Apple Inc. All Rights Reserved. | 2 * Copyright (C) 2008 Apple Inc. All Rights Reserved. |
3 * Copyright (C) 2011 Google Inc. All rights reserved. | 3 * Copyright (C) 2011 Google Inc. All rights reserved. |
4 * | 4 * |
5 * Redistribution and use in source and binary forms, with or without | 5 * Redistribution and use in source and binary forms, with or without |
6 * modification, are permitted provided that the following conditions | 6 * modification, are permitted provided that the following conditions |
7 * are met: | 7 * are met: |
8 * 1. Redistributions of source code must retain the above copyright | 8 * 1. 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 * 2. Redistributions in binary form must reproduce the above copyright | 10 * 2. Redistributions in binary form must reproduce the above copyright |
(...skipping 449 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
460 function didEvaluate(result, wasThrown) | 460 function didEvaluate(result, wasThrown) |
461 { | 461 { |
462 if (objectGroup === "console") | 462 if (objectGroup === "console") |
463 this.sidebarPanes.scopechain.update(this._presentationModel.sele
ctedCallFrame); | 463 this.sidebarPanes.scopechain.update(this._presentationModel.sele
ctedCallFrame); |
464 if (returnByValue) | 464 if (returnByValue) |
465 callback(null, wasThrown, wasThrown ? null : result); | 465 callback(null, wasThrown, wasThrown ? null : result); |
466 else | 466 else |
467 callback(WebInspector.RemoteObject.fromPayload(result), wasThrow
n); | 467 callback(WebInspector.RemoteObject.fromPayload(result), wasThrow
n); |
468 } | 468 } |
469 var selectedCallFrame = this._presentationModel.selectedCallFrame; | 469 var selectedCallFrame = this._presentationModel.selectedCallFrame; |
470 selectedCallFrame.evaluate(code, objectGroup, includeCommandLineAPI, ret
urnByValue, didEvaluate.bind(this)); | 470 if (selectedCallFrame) |
| 471 selectedCallFrame.evaluate(code, objectGroup, includeCommandLineAPI,
returnByValue, didEvaluate.bind(this)); |
471 }, | 472 }, |
472 | 473 |
473 getSelectedCallFrameVariables: function(callback) | 474 getSelectedCallFrameVariables: function(callback) |
474 { | 475 { |
475 var result = { this: true }; | 476 var result = { this: true }; |
476 | 477 |
477 var selectedCallFrame = this._presentationModel.selectedCallFrame; | 478 var selectedCallFrame = this._presentationModel.selectedCallFrame; |
478 if (!selectedCallFrame) | 479 if (!selectedCallFrame) |
479 callback(result); | 480 callback(result); |
480 | 481 |
(...skipping 809 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1290 }, | 1291 }, |
1291 | 1292 |
1292 suggestedFileName: function() | 1293 suggestedFileName: function() |
1293 { | 1294 { |
1294 var names = this._scriptsPanel._folderAndDisplayNameForScriptURL(this._u
iSourceCode.url); | 1295 var names = this._scriptsPanel._folderAndDisplayNameForScriptURL(this._u
iSourceCode.url); |
1295 return names.displayName || "untitled.js"; | 1296 return names.displayName || "untitled.js"; |
1296 } | 1297 } |
1297 } | 1298 } |
1298 | 1299 |
1299 WebInspector.SourceFrameDelegateForScriptsPanel.prototype.__proto__ = WebInspect
or.SourceFrameDelegate.prototype; | 1300 WebInspector.SourceFrameDelegateForScriptsPanel.prototype.__proto__ = WebInspect
or.SourceFrameDelegate.prototype; |
OLD | NEW |