Bug 1221808 - have the control centre crop the end for URIs without a host. r=rbarnes
authorMark Hammond <mhammond@skippinet.com.au>
Tue, 29 Dec 2015 15:46:46 +1100
changeset 277860 83cb1c2445fa081a67d379d975557afd56bf4979
parent 277772 36634a31d101cab18c462d46fca07a14fdd519a1
child 277861 4228fd8ef72fd99cafe4826473593b4ffb81b273
push id69628
push usercbook@mozilla.com
push dateWed, 30 Dec 2015 11:16:09 +0000
treeherdermozilla-inbound@b493cf33851f [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersrbarnes
bugs1221808
milestone46.0a1
first release with
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
last release without
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
Bug 1221808 - have the control centre crop the end for URIs without a host. r=rbarnes
browser/base/content/browser.js
--- a/browser/base/content/browser.js
+++ b/browser/base/content/browser.js
@@ -7092,16 +7092,19 @@ var gIdentityHandler = {
       host = this.getEffectiveHost();
     } catch (e) {
       // Some URIs might have no hosts.
     }
 
     // Fallback for special protocols.
     if (!host) {
       host = this._uri.specIgnoringRef;
+      // Special URIs without a host (eg, about:) should crop the end so
+      // the protocol can be seen.
+      crop = "end";
     }
 
     // Fill in the CA name if we have a valid TLS certificate.
     if (this._isSecure) {
       verifier = this._identityBox.tooltipText;
     }
 
     // Fill in organization information if we have a valid EV certificate.