OLD | NEW |
1 /* | 1 /* |
2 * Copyright (C) 2011 Google Inc. All rights reserved. | 2 * Copyright (C) 2011 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 93 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
104 return false; | 104 return false; |
105 this._evaluateInConsole(this.textEditor.copyRange(selection)); | 105 this._evaluateInConsole(this.textEditor.copyRange(selection)); |
106 return true; | 106 return true; |
107 }, | 107 }, |
108 | 108 |
109 /** | 109 /** |
110 * @param {string} expression | 110 * @param {string} expression |
111 */ | 111 */ |
112 _evaluateInConsole: function(expression) | 112 _evaluateInConsole: function(expression) |
113 { | 113 { |
114 WebInspector.console.show(); | |
115 WebInspector.console.evaluate(expression); | 114 WebInspector.console.evaluate(expression); |
116 }, | 115 }, |
117 | 116 |
118 // View events | 117 // View events |
119 wasShown: function() | 118 wasShown: function() |
120 { | 119 { |
121 WebInspector.UISourceCodeFrame.prototype.wasShown.call(this); | 120 WebInspector.UISourceCodeFrame.prototype.wasShown.call(this); |
122 }, | 121 }, |
123 | 122 |
124 willHide: function() | 123 willHide: function() |
(...skipping 538 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
663 this._uiSourceCode.removeEventListener(WebInspector.UISourceCode.Events.
ConsoleMessageRemoved, this._consoleMessageRemoved, this); | 662 this._uiSourceCode.removeEventListener(WebInspector.UISourceCode.Events.
ConsoleMessageRemoved, this._consoleMessageRemoved, this); |
664 this._uiSourceCode.removeEventListener(WebInspector.UISourceCode.Events.
ConsoleMessagesCleared, this._consoleMessagesCleared, this); | 663 this._uiSourceCode.removeEventListener(WebInspector.UISourceCode.Events.
ConsoleMessagesCleared, this._consoleMessagesCleared, this); |
665 this._uiSourceCode.removeEventListener(WebInspector.UISourceCode.Events.
SourceMappingChanged, this._onSourceMappingChanged, this); | 664 this._uiSourceCode.removeEventListener(WebInspector.UISourceCode.Events.
SourceMappingChanged, this._onSourceMappingChanged, this); |
666 this._uiSourceCode.removeEventListener(WebInspector.UISourceCode.Events.
WorkingCopyChanged, this._workingCopyChanged, this); | 665 this._uiSourceCode.removeEventListener(WebInspector.UISourceCode.Events.
WorkingCopyChanged, this._workingCopyChanged, this); |
667 this._uiSourceCode.removeEventListener(WebInspector.UISourceCode.Events.
WorkingCopyCommitted, this._workingCopyCommitted, this); | 666 this._uiSourceCode.removeEventListener(WebInspector.UISourceCode.Events.
WorkingCopyCommitted, this._workingCopyCommitted, this); |
668 WebInspector.UISourceCodeFrame.prototype.dispose.call(this); | 667 WebInspector.UISourceCodeFrame.prototype.dispose.call(this); |
669 }, | 668 }, |
670 | 669 |
671 __proto__: WebInspector.UISourceCodeFrame.prototype | 670 __proto__: WebInspector.UISourceCodeFrame.prototype |
672 } | 671 } |
OLD | NEW |