Bug 471753 - Show a link to the private browsing help page on mozilla.com in about:privatebrowsing; r=mconnor ui-r=mconnor,faaborg
authorEhsan Akhgari <ehsan.akhgari@gmail.com>
Sat, 21 Mar 2009 12:08:06 +0330
changeset 26441 a3bfe3a0c750a0baec4e9bca40b4c77a7b85b03f
parent 26440 49d7fee2e9b4579fc960cb9584b70a8ec8053fb2
child 26442 c2dad7721eea96744f05433dcba601a4b59c972a
push id6069
push userehsan.akhgari@gmail.com
push dateSat, 21 Mar 2009 08:42:09 +0000
treeherdermozilla-central@c2dad7721eea [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersmconnor, mconnor, faaborg
bugs471753
milestone1.9.2a1pre
Bug 471753 - Show a link to the private browsing help page on mozilla.com in about:privatebrowsing; r=mconnor ui-r=mconnor,faaborg
browser/components/privatebrowsing/content/aboutPrivateBrowsing.xhtml
browser/themes/gnomestripe/browser/aboutPrivateBrowsing.css
browser/themes/pinstripe/browser/aboutPrivateBrowsing.css
browser/themes/winstripe/browser/aboutPrivateBrowsing.css
--- a/browser/components/privatebrowsing/content/aboutPrivateBrowsing.xhtml
+++ b/browser/components/privatebrowsing/content/aboutPrivateBrowsing.xhtml
@@ -101,16 +101,24 @@
           selector = ".showNormal";
         }
 
         // Remove hidden elements to avoid bug 39098
         let elements = document.body.querySelectorAll(selector);
         for (let i = 0; i < elements.length; ++ i)
           elements[i].parentNode.removeChild(elements[i]);
 
+        // Set up the help link
+        let moreInfoURL = Cc["@mozilla.org/toolkit/URLFormatterService;1"].
+                          getService(Ci.nsIURLFormatter).
+                          formatURLPref("app.support.baseURL");
+        let moreInfoLink = document.getElementById("moreInfoLink");
+        if (moreInfoLink)
+          moreInfoLink.setAttribute("href", moreInfoURL + "private-browsing");
+
         // Focus the location bar
         if (mainWindow.gURLBar)
           mainWindow.focusElement(mainWindow.gURLBar);
       }
     ]]></script>
   </head>
 
   <body dir="&locale.dir;"
@@ -148,13 +156,21 @@
                   accesskey="&privatebrowsingpage.startPrivateBrowsing.accesskey;"/>
         </div>
 
         <!-- Footer -->
         <div id="footerDesc">
           <p id="footerText" class="showPrivate">&privatebrowsingpage.howToStop;</p>
           <p id="footerTextNormal" class="showNormal">&privatebrowsingpage.howToStart;</p>
         </div>
+
+        <!-- More Info -->
+        <div id="moreInfo" class="showPrivate">
+          <p id="moreInfoText">
+            &privatebrowsingpage.moreInfo;
+            <a id="moreInfoLink" target="_blank">&privatebrowsingpage.learnMore;</a>
+          </p>
+        </div>
       </div>
     </div>
 
   </body>
 </html>
--- a/browser/themes/gnomestripe/browser/aboutPrivateBrowsing.css
+++ b/browser/themes/gnomestripe/browser/aboutPrivateBrowsing.css
@@ -54,8 +54,18 @@ body.normal > #errorPageContainer {
 
 #startPrivateBrowsingDesc > button {
   -moz-margin-start: 0;
 }
 
 #footerDesc > p {
   font-size: 110%; /* to match the value set in chrome://global/skin/netError.css */
 }
+
+#moreInfoText {
+  font-size: 110%; /* to match the value set in chrome://global/skin/netError.css */
+  -moz-padding-start: 25px;
+  background: url("moz-icon://stock/gtk-dialog-info?size=menu") no-repeat top left;
+}
+
+body[dir="rtl"] #moreInfoText {
+  background-position: top right;
+}
--- a/browser/themes/pinstripe/browser/aboutPrivateBrowsing.css
+++ b/browser/themes/pinstripe/browser/aboutPrivateBrowsing.css
@@ -54,8 +54,18 @@ body.normal > #errorPageContainer {
 
 #startPrivateBrowsingDesc > button {
   -moz-margin-start: 0;
 }
 
 #footerDesc > p {
   font-size: 110%; /* to match the value set in chrome://global/skin/netError.css */
 }
+
+#moreInfoText {
+  font-size: 110%; /* to match the value set in chrome://global/skin/netError.css */
+  -moz-padding-start: 25px;
+  background: url("chrome://global/skin/icons/information-16.png") no-repeat top left;
+}
+
+body[dir="rtl"] #moreInfoText {
+  background-position: top right;
+}
--- a/browser/themes/winstripe/browser/aboutPrivateBrowsing.css
+++ b/browser/themes/winstripe/browser/aboutPrivateBrowsing.css
@@ -54,8 +54,18 @@ body.normal > #errorPageContainer {
 
 #startPrivateBrowsingDesc > button {
   -moz-margin-start: 0;
 }
 
 #footerDesc > p {
   font-size: 110%; /* to match the value set in chrome://global/skin/netError.css */
 }
+
+#moreInfoText {
+  font-size: 110%; /* to match the value set in chrome://global/skin/netError.css */
+  -moz-padding-start: 25px;
+  background: url("chrome://global/skin/icons/information-16.png") no-repeat top left;
+}
+
+body[dir="rtl"] #moreInfoText {
+  background-position: top right;
+}