Bug 1384078: Prevent enter key from closing extension panels. r?Gijs draft
authorKris Maglione <maglione.k@gmail.com>
Tue, 19 Sep 2017 16:37:07 -0700
changeset 667344 f768acea169a593bf7313a58378ca4b7c84d4e87
parent 667343 1303bbfb017d0a7446b959c9fcbe5bb65f296950
child 732351 133e6be36787de694a3567c413e4b9ef877fbf20
push id80675
push usermaglione.k@gmail.com
push dateTue, 19 Sep 2017 23:36:43 +0000
reviewersGijs
bugs1384078
milestone57.0a1
Bug 1384078: Prevent enter key from closing extension panels. r?Gijs MozReview-Commit-ID: DnpiIUc4RkH
browser/components/extensions/ExtensionPopups.jsm
--- a/browser/components/extensions/ExtensionPopups.jsm
+++ b/browser/components/extensions/ExtensionPopups.jsm
@@ -464,16 +464,17 @@ class ViewPopup extends BasePopup {
    * @returns {Promise<boolean>}
    *        Resolves when the browser is ready. Resolves to `false` if the
    *        browser was destroyed before it was fully loaded, and the popup
    *        should be closed, or `true` otherwise.
    */
   async attach(viewNode) {
     this.viewNode = viewNode;
     this.viewNode.addEventListener(this.DESTROY_EVENT, this);
+    this.viewNode.setAttribute("closemenu", "none");
 
     if (this.extension.remote) {
       this.panel.setAttribute("remote", "true");
     }
 
     // Wait until the browser element is fully initialized, and give it at least
     // a short grace period to finish loading its initial content, if necessary.
     //