Bug 952989 - Hide the find bar when the options flyout is displayed. r=mbrubeck, a=lsblakk
authorJim Mathies <jmathies@mozilla.com>
Fri, 10 Jan 2014 10:56:26 -0600
changeset 175798 9734d99bf243ab24d47dd9d834bf25f01e74a2d1
parent 175797 37f7074626f66a420df38f8711183cff461ac099
child 175799 a15b1eecd003a275902f475fcda5913ee5b7b9ff
push id445
push userffxbld
push dateMon, 10 Mar 2014 22:05:19 +0000
treeherdermozilla-release@dc38b741b04e [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersmbrubeck, lsblakk
bugs952989
milestone28.0a2
Bug 952989 - Hide the find bar when the options flyout is displayed. r=mbrubeck, a=lsblakk
browser/metro/base/content/helperui/FindHelperUI.js
--- a/browser/metro/base/content/helperui/FindHelperUI.js
+++ b/browser/metro/base/content/helperui/FindHelperUI.js
@@ -53,16 +53,17 @@ var FindHelperUI = {
     // Listen for find assistant messages from content
     messageManager.addMessageListener("FindAssist:Show", this);
     messageManager.addMessageListener("FindAssist:Hide", this);
 
     // Listen for events where form assistant should be closed
     Elements.tabList.addEventListener("TabSelect", this, true);
     Elements.browsers.addEventListener("URLChanged", this, true);
     window.addEventListener("MozAppbarShowing", this);
+    window.addEventListener("MozFlyoutPanelShowing", this, false);
   },
 
   receiveMessage: function findHelperReceiveMessage(aMessage) {
     let json = aMessage.json;
     switch(aMessage.name) {
       case "FindAssist:Show":
         ContextUI.dismiss();
         this.status = json.result;
@@ -96,16 +97,17 @@ var FindHelperUI = {
             this.goToPrevious();
           } else {
             this.goToNext();
           }
         }
         break;
 
       case "MozAppbarShowing":
+      case "MozFlyoutPanelShowing":
         if (aEvent.target != this._container) {
           this.hide();
         }
         break;
     }
   },
 
   show: function findHelperShow() {