Bug 1043154 - Open Split console on ESC if the focus is inside source editor (style editor / debugger). r=bgrins
authorJayesh Choudhari <jayesh.choudhari17@gmail.com>
Wed, 06 Aug 2014 22:38:00 -0400
changeset 198579 5bf0bbcc85fbcba2ccb1ac2471990281c29811bf
parent 198578 2ead24c96a8e9e278fca79543c91aac03b031800
child 198580 0d125ed595c2f796e58cfdf43095142d54f807b4
push id27277
push userryanvm@gmail.com
push dateFri, 08 Aug 2014 20:25:17 +0000
treeherdermozilla-central@1d6500527f66 [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersbgrins
bugs1043154
milestone34.0a1
first release with
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
last release without
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
Bug 1043154 - Open Split console on ESC if the focus is inside source editor (style editor / debugger). r=bgrins
browser/devtools/debugger/debugger-view.js
browser/devtools/styleeditor/StyleSheetEditor.jsm
--- a/browser/devtools/debugger/debugger-view.js
+++ b/browser/devtools/debugger/debugger-view.js
@@ -208,16 +208,17 @@ let DebuggerView = {
   _initializeEditor: function(aCallback) {
     dumpn("Initializing the DebuggerView editor");
 
     let extraKeys = {};
     bindKey("_doTokenSearch", "tokenSearchKey");
     bindKey("_doGlobalSearch", "globalSearchKey", { alt: true });
     bindKey("_doFunctionSearch", "functionSearchKey");
     extraKeys[Editor.keyFor("jumpToLine")] = false;
+    extraKeys["Esc"] = false;
 
     function bindKey(func, key, modifiers = {}) {
       let key = document.getElementById(key).getAttribute("key");
       let shortcut = Editor.accel(key, modifiers);
       extraKeys[shortcut] = () => DebuggerView.Filtering[func]();
     }
 
     this.editor = new Editor({
--- a/browser/devtools/styleeditor/StyleSheetEditor.jsm
+++ b/browser/devtools/styleeditor/StyleSheetEditor.jsm
@@ -621,16 +621,18 @@ StyleSheetEditor.prototype = {
     bindings[Editor.accel(_("saveStyleSheet.commandkey"))] = () => {
       this.saveToFile(this.savedFile);
     };
 
     bindings["Shift-" + Editor.accel(_("saveStyleSheet.commandkey"))] = () => {
       this.saveToFile();
     };
 
+    bindings["Esc"] = false;
+
     return bindings;
   },
 
   /**
    * Clean up for this editor.
    */
   destroy: function() {
     if (this._sourceEditor) {