Bug 1500086 - While typing, show the Go button and hide the history dropmarker. r=mak
authorDão Gottwald <dao@mozilla.com>
Fri, 19 Oct 2018 15:58:57 +0000
changeset 490529 4aad71bbd52935e8cb99492d39d9e5643259e6d4
parent 490528 e688352c431d7a3daedd22f0243e9c10e25cf399
child 490530 68445fa636530442c2ac79c80f506e86ccaa838d
push id247
push userfmarier@mozilla.com
push dateSat, 27 Oct 2018 01:06:44 +0000
reviewersmak
bugs1500086
milestone64.0a1
Bug 1500086 - While typing, show the Go button and hide the history dropmarker. r=mak Differential Revision: https://phabricator.services.mozilla.com/D9106
browser/components/urlbar/UrlbarInput.jsm
--- a/browser/components/urlbar/UrlbarInput.jsm
+++ b/browser/components/urlbar/UrlbarInput.jsm
@@ -430,16 +430,22 @@ class UrlbarInput {
   }
 
   _on_input(event) {
     let value = event.target.value;
     this.valueIsTyped = true;
     this._untrimmedValue = value;
     this.window.gBrowser.userTypedValue = value;
 
+    if (value) {
+      this.setAttribute("usertyping", "true");
+    } else {
+      this.removeAttribute("usertyping");
+    }
+
     // XXX Fill in lastKey, and add anything else we need.
     this.controller.startQuery(new QueryContext({
       searchString: value,
       lastKey: "",
       maxResults: UrlbarPrefs.get("maxRichResults"),
       isPrivate: this.isPrivate,
     }));
   }