Bug 1364387 - Ignore spurious overflow event from the anonymous div containing the placeholder text. r?jaws
This event made us initially fade out the URL bar text in new windows despite the text not overflowing the textbox.
This is more visible in RTL builds as we right-align the URL bar value there.
MozReview-Commit-ID: IfLzQBhDXDt
--- a/browser/base/content/urlbarBindings.xml
+++ b/browser/base/content/urlbarBindings.xml
@@ -1012,16 +1012,21 @@ file, You can obtain one at http://mozil
break;
case "mousemove":
this._initURLTooltip();
break;
case "mouseout":
this._hideURLTooltip();
break;
case "overflow":
+ if (!this.value) {
+ // We initially get a spurious overflow event from the
+ // anonymous div containing the placeholder text; bail out.
+ break;
+ }
this.setAttribute("textoverflow", "true");
break;
case "underflow":
this.removeAttribute("textoverflow");
this._hideURLTooltip();
break;
}
]]></body>