Bug 601060 - Hovering links shows "moz-action:switchtab" text and hides "Switch to tab:" label in URL bar when it contains a switch-to-tab URL. r=dao
authorFrank Yan <fryn@frankyan.com>
Sat, 22 Jan 2011 12:21:35 +0100
changeset 61134 0718ec1414744ca58d21982ace95750039652626
parent 61133 ed2a0893d0cf6072675f0bdbb2190aaac78c3b0c
child 61135 dc22e591c18457f09a547ad620960e5fe63d5a3e
push id18238
push userdgottwald@mozilla.com
push dateSat, 22 Jan 2011 11:23:34 +0000
treeherdermozilla-central@52d6439d7d19 [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersdao
bugs601060
milestone2.0b10pre
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 601060 - Hovering links shows "moz-action:switchtab" text and hides "Switch to tab:" label in URL bar when it contains a switch-to-tab URL. r=dao
browser/base/content/browser.css
browser/base/content/browser.xul
browser/base/content/urlbarBindings.xml
browser/themes/gnomestripe/browser/browser.css
browser/themes/pinstripe/browser/browser.css
browser/themes/winstripe/browser/browser.css
--- a/browser/base/content/browser.css
+++ b/browser/base/content/browser.css
@@ -274,17 +274,17 @@ panel[noactions] > richlistbox > richlis
 panel[noactions] > richlistbox > richlistitem[type~="action"] > .ac-url-box > .ac-action-icon {
   visibility: collapse;
 }
 
 panel[noactions] > richlistbox > richlistitem[type~="action"] > .ac-url-box > .ac-url > .ac-url-text {
   visibility: visible;
 }
 
-#urlbar:not([actiontype]) > #urlbar-display {
+#urlbar:not([actiontype]) > #urlbar-display-box {
   display: none;
 }
 
 #wrapper-urlbar-container > #urlbar-container > #urlbar {
   -moz-user-input: disabled;
   cursor: -moz-grab;
 }
 
--- a/browser/base/content/browser.xul
+++ b/browser/base/content/browser.xul
@@ -566,17 +566,19 @@
                        onerror="this.removeAttribute('src');"/>
               </stack>
               <hbox id="identity-icon-labels">
                 <label id="identity-icon-label" class="plain" flex="1"/>
                 <label id="identity-icon-country-label" class="plain"/>
               </hbox>
             </hbox>
           </box>
-          <label id="urlbar-display" value="&urlbar.switchToTab.label;"/>
+          <box id="urlbar-display-box" align="center">
+            <label id="urlbar-display" value="&urlbar.switchToTab.label;"/>
+          </box>
           <hbox id="urlbar-icons">
             <image id="page-report-button"
                    class="urlbar-icon"
                    hidden="true"
                    tooltiptext="&pageReportIcon.tooltip;"
                    onclick="gPopupBlockerObserver.onReportButtonClick(event);"/>
 
             <image id="star-button"
--- a/browser/base/content/urlbarBindings.xml
+++ b/browser/base/content/urlbarBindings.xml
@@ -778,17 +778,18 @@
               overLinkHost.flex = 1;
               overLinkHost.crop = "end";
             }
             overLinkPath.crop = host ? "start" : "end";
             overLink.style.minWidth = maxWidth + "px";
             overLink.style.maxWidth = maxWidth + "px";
           }
 
-          this._originLabel.value = this.value;
+          var action = this._parseActionUrl(this._value);
+          this._originLabel.value = action ? action.param : this._value;
         ]]></body>
       </method>
 
       <field name="_numNoActionsKeys"><![CDATA[
         0
       ]]></field>
 
       <method name="_clearNoActions">
--- a/browser/themes/gnomestripe/browser/browser.css
+++ b/browser/themes/gnomestripe/browser/browser.css
@@ -938,27 +938,29 @@ toolbar[iconsize="small"] #feed-button {
   -moz-margin-start: -4px;
 }
 
 #urlbar-search-splitter + #urlbar-container > #urlbar ,
 #urlbar-search-splitter + #search-container > #searchbar > .searchbar-textbox {
   -moz-margin-start: 0;
 }
 
-#urlbar-display {
-  margin-top: -2px;
-  margin-bottom: -2px;
-  padding-top: 3px;
-  padding-bottom: 2px;
-  -moz-padding-end: 3px;
-  color: GrayText;
+#urlbar-display-box {
+  margin-top: -1px;
+  margin-bottom: -1px;
   -moz-border-end: 1px solid #AAA;
   -moz-margin-end: 3px;
 }
 
+#urlbar-display {
+  margin-top: 0;
+  margin-bottom: 0;
+  color: GrayText;
+}
+
 #PopupAutoComplete,
 #PopupAutoCompleteRichResult {
   direction: ltr !important;
 }
 
 #PopupAutoComplete:-moz-locale-dir(rtl) > tree > treerows {
   direction: rtl;
 }
--- a/browser/themes/pinstripe/browser/browser.css
+++ b/browser/themes/pinstripe/browser/browser.css
@@ -881,27 +881,27 @@ toolbar[mode="icons"] #zoom-in-button {
 #urlbar-throbber {
   list-style-image: url("chrome://browser/skin/places/searching_16.png");
 }
 
 #wrapper-urlbar-container[place="palette"] {
   max-width: 20em;
 }
 
-#urlbar-display {
-  margin-top: -3px;
-  margin-bottom: -2px;
-  padding-top: 3px;
-  padding-bottom: 2px;
-  -moz-padding-end: 3px;
-  color: GrayText;
+#urlbar-display-box {
   -moz-border-end: 1px solid #AAA;
   -moz-margin-end: 3px;
 }
 
+#urlbar-display {
+  margin-top: 0;
+  margin-bottom: 0;
+  color: GrayText;
+}
+
 #PopupAutoCompleteRichResult {
   direction: ltr !important;
   margin-top: 2px;
 }
 
 /* over-link in location bar */
 
 .urlbar-origin-label {
@@ -1416,22 +1416,22 @@ sidebarheader {
   -moz-appearance: none;
 }
 
 #sidebar-splitter {
   -moz-border-start: none;
   -moz-border-end: 1px solid #404040;
   min-width: 1px;
   width: 1px;
-  background-image: none !important;       
-} 
+  background-image: none !important;
+}
 
 #sidebar-title {
   color: #535f6d;
-  font-weight: bold;  
+  font-weight: bold;
 }
 
 #sidebar-throbber[loading="true"] {
   list-style-image: url("chrome://global/skin/icons/loading_16.png");
 }
 
 sidebarheader > .tabs-closebutton > .toolbarbutton-text {
   display: none;
--- a/browser/themes/winstripe/browser/browser.css
+++ b/browser/themes/winstripe/browser/browser.css
@@ -1123,27 +1123,29 @@ html|*.urlbar-input:-moz-lwtheme:-moz-pl
   -moz-margin-start: 0;
 }
 
 .urlbar-frontcap-and-textbox {
   direction: ltr;
   -moz-box-align: stretch;
 }
 
-#urlbar-display {
+#urlbar-display-box {
   margin-top: -2px;
   margin-bottom: -2px;
-  padding-top: 3px;
-  padding-bottom: 2px;
-  -moz-padding-end: 3px;
-  color: GrayText;
   -moz-border-end: 1px solid #AAA;
   -moz-margin-end: 3px;
 }
 
+#urlbar-display {
+  margin-top: 0;
+  margin-bottom: 0;
+  color: GrayText;
+}
+
 /* over-link in location bar */
 
 .urlbar-origin-label {
   padding: 0 0 0 4px;
   margin: 0;
 }
 
 .urlbar-over-link-box {