Bug 611063 - Android Content Menu overlays Find in Page/Form Filler but still allows typing [r=mfinkle]
authorMatt Brubeck <mbrubeck@mozilla.com>
Thu, 09 Dec 2010 11:13:55 -0500
changeset 67097 924f2735f961a0f8083c48fc398510ad361ea3df
parent 67096 7fcfa6ea4b1294e5e84d3fab39d7bc9ce6efe0d1
child 67098 90999965babda98b899b90c92d2ea7ea338acadb
push id1
push userroot
push dateTue, 26 Apr 2011 22:38:44 +0000
treeherdermozilla-beta@bfdb6e623a36 [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersmfinkle
bugs611063
Bug 611063 - Android Content Menu overlays Find in Page/Form Filler but still allows typing [r=mfinkle]
mobile/chrome/content/browser-ui.js
--- a/mobile/chrome/content/browser-ui.js
+++ b/mobile/chrome/content/browser-ui.js
@@ -2967,22 +2967,32 @@ var AppMenu = {
     return this.panel = document.getElementById("appmenu");
   },
 
   show: function show() {
     if (BrowserUI.activePanel || BrowserUI.isPanelVisible())
       return;
     this.panel.setAttribute("count", this.panel.childNodes.length);
     this.panel.collapsed = false;
+
+    addEventListener("keypress", this, true);
+
     BrowserUI.lockToolbar();
     BrowserUI.pushPopup(this, [this.panel, Elements.toolbarContainer]);
   },
 
   hide: function hide() {
     this.panel.collapsed = true;
+
+    removeEventListener("keypress", this, true);
+
     BrowserUI.unlockToolbar();
     BrowserUI.popPopup(this);
   },
 
   toggle: function toggle() {
     this.panel.collapsed ? this.show() : this.hide();
+  },
+
+  handleEvent: function handleEvent(aEvent) {
+    this.hide();
   }
 };