Bug 609069 - about:rights shows XML parsing error [r=gavin]
authorMark Finkle <mfinkle@mozilla.com>
Tue, 02 Nov 2010 17:50:00 -0400
changeset 66945 99c8792f7a4174a9b022077190452974ce7c453a
parent 66944 1d5bd1f64a7054ae2e3f7fc1cedf01a337820e6f
child 66946 5cd1a037b0dde012f102c06cee0318eb1af6fec7
push id1
push userroot
push dateTue, 26 Apr 2011 22:38:44 +0000
treeherdermozilla-beta@bfdb6e623a36 [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersgavin
bugs609069
Bug 609069 - about:rights shows XML parsing error [r=gavin]
mobile/chrome/content/aboutRights.xhtml
mobile/chrome/jar.mn
mobile/components/AboutRedirector.js
new file mode 100644
--- /dev/null
+++ b/mobile/chrome/content/aboutRights.xhtml
@@ -0,0 +1,128 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE html [
+  <!ENTITY % htmlDTD PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "DTD/xhtml1-strict.dtd">
+  %htmlDTD;
+  <!ENTITY % brandDTD SYSTEM "chrome://branding/locale/brand.dtd">
+  %brandDTD;
+  <!ENTITY % aboutRightsDTD SYSTEM "chrome://global/locale/aboutRights.dtd">
+  %aboutRightsDTD;
+]>
+# ***** BEGIN LICENSE BLOCK *****
+# Version: MPL 1.1/GPL 2.0/LGPL 2.1
+#
+# The contents of this file are subject to the Mozilla Public License Version
+# 1.1 (the "License"); you may not use this file except in compliance with
+# the License. You may obtain a copy of the License at
+# http://www.mozilla.org/MPL/
+#
+# Software distributed under the License is distributed on an "AS IS" basis,
+# WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
+# for the specific language governing rights and limitations under the
+# License.
+#
+# The Original Code is mozilla.org code.
+#
+# The Initial Developer of the Original Code is
+# Gervase Markham.
+# Portions created by the Initial Developer are Copyright (C) 2008
+# the Initial Developer. All Rights Reserved.
+#
+# Contributor(s):
+#   Justin Dolske <dolske@mozilla.com>
+#
+# Alternatively, the contents of this file may be used under the terms of
+# either the GNU General Public License Version 2 or later (the "GPL"), or
+# the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
+# in which case the provisions of the GPL or the LGPL are applicable instead
+# of those above. If you wish to allow use of your version of this file only
+# under the terms of either the GPL or the LGPL, and not to allow others to
+# use your version of this file under the terms of the MPL, indicate your
+# decision by deleting the provisions above and replace them with the notice
+# and other provisions required by the GPL or the LGPL. If you do not delete
+# the provisions above, a recipient may use your version of this file under
+# the terms of any one of the MPL, the GPL or the LGPL.
+#
+# ***** END LICENSE BLOCK *****
+
+<html xmlns="http://www.w3.org/1999/xhtml">
+
+<head>
+  <title>&rights.pagetitle;</title>
+  <link rel="stylesheet" href="chrome://global/skin/about.css" type="text/css"/>
+</head>
+
+<body id="your-rights" dir="&rights.locale-direction;" class="aboutPageWideContainer">
+
+<h1>&rights.intro-header;</h1>
+
+<p>&rights.intro;</p>
+
+<ul>
+  <li>&rights.intro-point1a;<a href="http://www.mozilla.org/MPL/">&rights.intro-point1b;</a>&rights.intro-point1c;</li>
+# Point 2 discusses Mozilla trademarks, and isn't needed when the build is unbranded.
+# Point 3 discusses privacy policy, unbranded builds get a placeholder (for the vendor to replace)
+# Point 4 discusses web service terms, unbranded builds gets a placeholder (for the vendor to replace)
+  <li>&rights.intro-point2-a;<a href="http://www.mozilla.org/foundation/trademarks/policy.html">&rights.intro-point2-b;</a>&rights.intro-point2-c;</li>
+  <li>&rights.intro-point2.5;</li>
+  <li>&rights2.intro-point3a;<a href="http://www.mozilla.com/legal/privacy/">&rights2.intro-point3b;</a>&rights.intro-point3c;</li>
+  <li>&rights2.intro-point4a;<a href="about:rights#webservices" onclick="showServices();">&rights.intro-point4b;</a>&rights.intro-point4c;</li>
+</ul>
+
+<div id="webservices-container">
+  <a name="webservices"/>
+  <h3>&rights2.webservices-header;</h3>
+
+  <p>&rights2.webservices-a;<a href="about:rights#disabling-webservices" onclick="showDisablingServices();">&rights2.webservices-b;</a>&rights2.webservices-c;</p>
+
+  <div id="disabling-webservices-container" style="margin-left:40px;">
+    <a name="disabling-webservices"/>
+    <!-- XXX Safe Browsing is not enabled in Firefox Mobile -->
+    <!--
+    <p><strong>&rights.safebrowsing-a;</strong>&rights.safebrowsing-b;</p>
+    <ul>
+      <li>&rights.safebrowsing-term1;</li>
+      <li>&rights.safebrowsing-term2;</li>
+      <li>&rights.safebrowsing-term3;</li>
+      <li>&rights.safebrowsing-term4;</li>
+    </ul>
+    -->
+
+    <p><strong>&rights.locationawarebrowsing-a;</strong>&rights.locationawarebrowsing-b;</p>
+    <ul>
+      <li>&rights.locationawarebrowsing-term1a;<code>&rights.locationawarebrowsing-term1b;</code></li>
+      <li>&rights.locationawarebrowsing-term2;</li>
+      <li>&rights.locationawarebrowsing-term3;</li>
+      <li>&rights.locationawarebrowsing-term4;</li>
+    </ul>
+  </div>
+
+  <ol>
+# Terms only apply to official builds, unbranded builds get a placeholder.
+    <li>&rights2.webservices-term1;</li>
+    <li>&rights.webservices-term2;</li>
+    <li>&rights2.webservices-term3;</li>
+    <li><strong>&rights.webservices-term4;</strong></li>
+    <li><strong>&rights.webservices-term5;</strong></li>
+    <li>&rights.webservices-term6;</li>
+    <li>&rights.webservices-term7;</li>
+  </ol>
+</div>
+
+<script type="application/javascript"><![CDATA[
+  var servicesDiv = document.getElementById("webservices-container");
+  servicesDiv.style.display = "none";
+
+  function showServices() {
+    servicesDiv.style.display = "";
+  }
+  
+  var disablingServicesDiv = document.getElementById("disabling-webservices-container");
+  disablingServicesDiv.style.display = "none";
+  
+  function showDisablingServices() {
+    disablingServicesDiv.style.display = "";
+  }
+]]></script>
+
+</body>
+</html>
--- a/mobile/chrome/jar.mn
+++ b/mobile/chrome/jar.mn
@@ -10,16 +10,17 @@ chrome.jar:
   content/firstrun/nav-arrow.png       (content/firstrun/nav-arrow.png)
 
 * content/about.xhtml                  (content/about.xhtml)
   content/config.xul                   (content/config.xul)
   content/config.js                    (content/config.js)
   content/aboutCertError.xhtml         (content/aboutCertError.xhtml)
   content/aboutCertError.css           (content/aboutCertError.css)
   content/aboutHome.xhtml              (content/aboutHome.xhtml)
+* content/aboutRights.xhtml            (content/aboutRights.xhtml)
   content/languages.properties         (content/languages.properties)
 * content/browser.xul                  (content/browser.xul)
 * content/browser.js                   (content/browser.js)
 * content/browser-ui.js                (content/browser-ui.js)
   content/content.js                   (content/content.js)
   content/commandUtil.js               (content/commandUtil.js)
 * content/bindings.xml                 (content/bindings.xml)
   content/tabs.xml                     (content/tabs.xml)
--- a/mobile/components/AboutRedirector.js
+++ b/mobile/components/AboutRedirector.js
@@ -54,17 +54,17 @@ let modules = {
   get firefox() this.fennec,
 
   firstrun: {
     uri: "chrome://browser/content/firstrun/firstrun.xhtml",
     privileged: true
   },
   rights: {
 #ifdef MOZ_OFFICIAL_BRANDING
-    uri: "chrome://global/content/aboutRights.xhtml",
+    uri: "chrome://browser/content/aboutRights.xhtml",
 #else
     uri: "chrome://global/content/aboutRights-unbranded.xhtml",
 #endif
     privileged: false
   },
   certerror: {
     uri: "chrome://browser/content/aboutCertError.xhtml",
     privileged: true