Bug 513023 - Move about:rights content to toolkit. r=benjamin

--HG--
rename : browser/base/content/aboutRights.xhtml => toolkit/content/aboutRights-unbranded.xhtml
rename : browser/base/content/aboutRights.xhtml => toolkit/content/aboutRights.xhtml
rename : browser/locales/en-US/chrome/browser/aboutRights.dtd => toolkit/locales/en-US/chrome/global/aboutRights.dtd
rename : browser/locales/en-US/chrome/browser/aboutRights.properties => toolkit/locales/en-US/chrome/global/aboutRights.properties
This commit is contained in:
Gavin Sharp 2009-09-04 14:27:14 +02:00
parent aa346b4676
commit 020d7878f9
12 changed files with 109 additions and 23 deletions

View File

@ -81,7 +81,3 @@ ifneq ($(OS_ARCH),WINCE)
DEFINES += -DCONTEXT_COPY_IMAGE_CONTENTS=1 DEFINES += -DCONTEXT_COPY_IMAGE_CONTENTS=1
endif endif
endif endif
ifdef MOZILLA_OFFICIAL
DEFINES += -DOFFICIAL_BUILD=1
endif

View File

@ -13,7 +13,6 @@ browser.jar:
* content/browser/aboutDialog.xul (content/aboutDialog.xul) * content/browser/aboutDialog.xul (content/aboutDialog.xul)
* content/browser/aboutDialog.js (content/aboutDialog.js) * content/browser/aboutDialog.js (content/aboutDialog.js)
content/browser/aboutDialog.css (content/aboutDialog.css) content/browser/aboutDialog.css (content/aboutDialog.css)
* content/browser/aboutRights.xhtml (content/aboutRights.xhtml)
* content/browser/aboutRobots.xhtml (content/aboutRobots.xhtml) * content/browser/aboutRobots.xhtml (content/aboutRobots.xhtml)
content/browser/aboutRobots-icon.png (content/aboutRobots-icon.png) content/browser/aboutRobots-icon.png (content/aboutRobots-icon.png)
content/browser/aboutRobots-icon-rtl.png (content/aboutRobots-icon-rtl.png) content/browser/aboutRobots-icon-rtl.png (content/aboutRobots-icon-rtl.png)

View File

@ -80,7 +80,12 @@ static RedirEntry kRedirMap[] = {
nsIAboutModule::ALLOW_SCRIPT }, nsIAboutModule::ALLOW_SCRIPT },
{ "privatebrowsing", "chrome://browser/content/aboutPrivateBrowsing.xhtml", { "privatebrowsing", "chrome://browser/content/aboutPrivateBrowsing.xhtml",
nsIAboutModule::ALLOW_SCRIPT }, nsIAboutModule::ALLOW_SCRIPT },
{ "rights", "chrome://browser/content/aboutRights.xhtml", { "rights",
#ifdef OFFICIAL_BUILD
"chrome://global/content/aboutRights.xhtml",
#else
"chrome://global/content/aboutRights-unbranded.xhtml",
#endif
nsIAboutModule::URI_SAFE_FOR_UNTRUSTED_CONTENT | nsIAboutModule::URI_SAFE_FOR_UNTRUSTED_CONTENT |
nsIAboutModule::ALLOW_SCRIPT }, nsIAboutModule::ALLOW_SCRIPT },
{ "robots", "chrome://browser/content/aboutRobots.xhtml", { "robots", "chrome://browser/content/aboutRobots.xhtml",

View File

@ -58,4 +58,8 @@ CPPSRCS = AboutRedirector.cpp
LOCAL_INCLUDES = -I$(srcdir)/../build LOCAL_INCLUDES = -I$(srcdir)/../build
ifdef MOZILLA_OFFICIAL
DEFINES += -DOFFICIAL_BUILD=1
endif
include $(topsrcdir)/config/rules.mk include $(topsrcdir)/config/rules.mk

View File

@ -494,7 +494,7 @@ BrowserGlue.prototype = {
var notifyBox = browser.getNotificationBox(); var notifyBox = browser.getNotificationBox();
var brandBundle = this._bundleService.createBundle("chrome://branding/locale/brand.properties"); var brandBundle = this._bundleService.createBundle("chrome://branding/locale/brand.properties");
var rightsBundle = this._bundleService.createBundle("chrome://browser/locale/aboutRights.properties"); var rightsBundle = this._bundleService.createBundle("chrome://global/locale/aboutRights.properties");
var buttonLabel = rightsBundle.GetStringFromName("buttonLabel"); var buttonLabel = rightsBundle.GetStringFromName("buttonLabel");
var buttonAccessKey = rightsBundle.GetStringFromName("buttonAccessKey"); var buttonAccessKey = rightsBundle.GetStringFromName("buttonAccessKey");

View File

@ -5,8 +5,6 @@
locale/browser/aboutCertError.dtd (%chrome/browser/aboutCertError.dtd) locale/browser/aboutCertError.dtd (%chrome/browser/aboutCertError.dtd)
locale/browser/aboutDialog.dtd (%chrome/browser/aboutDialog.dtd) locale/browser/aboutDialog.dtd (%chrome/browser/aboutDialog.dtd)
locale/browser/aboutPrivateBrowsing.dtd (%chrome/browser/aboutPrivateBrowsing.dtd) locale/browser/aboutPrivateBrowsing.dtd (%chrome/browser/aboutPrivateBrowsing.dtd)
locale/browser/aboutRights.dtd (%chrome/browser/aboutRights.dtd)
locale/browser/aboutRights.properties (%chrome/browser/aboutRights.properties)
locale/browser/aboutRobots.dtd (%chrome/browser/aboutRobots.dtd) locale/browser/aboutRobots.dtd (%chrome/browser/aboutRobots.dtd)
locale/browser/aboutSessionRestore.dtd (%chrome/browser/aboutSessionRestore.dtd) locale/browser/aboutSessionRestore.dtd (%chrome/browser/aboutSessionRestore.dtd)
locale/browser/credits.dtd (%chrome/browser/credits.dtd) locale/browser/credits.dtd (%chrome/browser/credits.dtd)

View File

@ -0,0 +1,93 @@
<?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 % securityPrefsDTD SYSTEM "chrome://browser/locale/preferences/security.dtd">
%securityPrefsDTD;
<!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-point3-unbranded;</li>
<li>&rights.intro-point4a-unbranded;<a href="about:rights#webservices" onclick="showServices();">&rights.intro-point4b-unbranded;</a>&rights.intro-point4c-unbranded;</li>
</ul>
<div id="webservices-container">
<a name="webservices"/>
<h3>&rights.webservices-header;</h3>
<p>&rights.webservices-unbranded;</p>
<ol>
# Terms only apply to official builds, unbranded builds get a placeholder.
<li>&rights.webservices-term1-unbranded;</li>
</ol>
</div>
<script type="application/x-javascript"><![CDATA[
var servicesDiv = document.getElementById("webservices-container");
servicesDiv.style.display = "none";
function showServices() {
servicesDiv.style.display = "";
}
]]></script>
</body>
</html>

View File

@ -6,7 +6,7 @@
%brandDTD; %brandDTD;
<!ENTITY % securityPrefsDTD SYSTEM "chrome://browser/locale/preferences/security.dtd"> <!ENTITY % securityPrefsDTD SYSTEM "chrome://browser/locale/preferences/security.dtd">
%securityPrefsDTD; %securityPrefsDTD;
<!ENTITY % aboutRightsDTD SYSTEM "chrome://browser/locale/aboutRights.dtd"> <!ENTITY % aboutRightsDTD SYSTEM "chrome://global/locale/aboutRights.dtd">
%aboutRightsDTD; %aboutRightsDTD;
]> ]>
# ***** BEGIN LICENSE BLOCK ***** # ***** BEGIN LICENSE BLOCK *****
@ -61,31 +61,21 @@
<ul> <ul>
<li>&rights.intro-point1a;<a href="http://www.mozilla.org/MPL/">&rights.intro-point1b;</a>&rights.intro-point1c;</li> <li>&rights.intro-point1a;<a href="http://www.mozilla.org/MPL/">&rights.intro-point1b;</a>&rights.intro-point1c;</li>
#ifdef OFFICIAL_BUILD
# Point 2 discusses Mozilla trademarks, and isn't needed when the build is unbranded. # 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 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) # Point 4 discusses web service terms, unbranded builds gets a placeholder (for the vendor to replace)
<li>&rights.intro-point2a;<a href="http://www.mozilla.org/foundation/trademarks/policy.html">&rights.intro-point2b;</a>&rights.intro-point2c;</li> <li>&rights.intro-point2a;<a href="http://www.mozilla.org/foundation/trademarks/policy.html">&rights.intro-point2b;</a>&rights.intro-point2c;</li>
<li>&rights.intro-point3a;<a href="http://www.mozilla.com/legal/privacy/">&rights.intro-point3b;</a>&rights.intro-point3c;</li> <li>&rights.intro-point3a;<a href="http://www.mozilla.com/legal/privacy/">&rights.intro-point3b;</a>&rights.intro-point3c;</li>
<li>&rights.intro-point4a;<a href="about:rights#webservices" onclick="showServices();">&rights.intro-point4b;</a>&rights.intro-point4c;</li> <li>&rights.intro-point4a;<a href="about:rights#webservices" onclick="showServices();">&rights.intro-point4b;</a>&rights.intro-point4c;</li>
#else
<li>&rights.intro-point3-unbranded;</li>
<li>&rights.intro-point4a-unbranded;<a href="about:rights#webservices" onclick="showServices();">&rights.intro-point4b-unbranded;</a>&rights.intro-point4c-unbranded;</li>
#endif
</ul> </ul>
<div id="webservices-container"> <div id="webservices-container">
<a name="webservices"/> <a name="webservices"/>
<h3>&rights.webservices-header;</h3> <h3>&rights.webservices-header;</h3>
#ifdef OFFICIAL_BUILD
<p>&rights.webservices-a;<code>&rights.webservices-b;</code>&rights.webservices-c;</p> <p>&rights.webservices-a;<code>&rights.webservices-b;</code>&rights.webservices-c;</p>
#else
<p>&rights.webservices-unbranded;</p>
#endif
<ol> <ol>
#ifdef OFFICIAL_BUILD
# Terms only apply to official builds, unbranded builds get a placeholder. # Terms only apply to official builds, unbranded builds get a placeholder.
<li>&rights.webservices-term1;</li> <li>&rights.webservices-term1;</li>
<li>&rights.webservices-term2;</li> <li>&rights.webservices-term2;</li>
@ -94,9 +84,6 @@
<li><strong>&rights.webservices-term5;</strong></li> <li><strong>&rights.webservices-term5;</strong></li>
<li>&rights.webservices-term6;</li> <li>&rights.webservices-term6;</li>
<li>&rights.webservices-term7;</li> <li>&rights.webservices-term7;</li>
#else
<li>&rights.webservices-term1-unbranded;</li>
#endif
</ol> </ol>
</div> </div>

View File

@ -11,6 +11,8 @@ toolkit.jar:
content/global/textbox.css (textbox.css) content/global/textbox.css (textbox.css)
content/global/menulist.css (menulist.css) content/global/menulist.css (menulist.css)
* content/global/about.xhtml (about.xhtml) * content/global/about.xhtml (about.xhtml)
* content/global/aboutRights.xhtml (aboutRights.xhtml)
* content/global/aboutRights-unbranded.xhtml (aboutRights-unbranded.xhtml)
content/global/directionDetector.html content/global/directionDetector.html
content/global/plugins.html content/global/plugins.html
content/global/plugins.css content/global/plugins.css

View File

@ -3,6 +3,8 @@
@AB_CD@.jar: @AB_CD@.jar:
% locale global @AB_CD@ %locale/@AB_CD@/global/ % locale global @AB_CD@ %locale/@AB_CD@/global/
locale/@AB_CD@/global/about.dtd (%chrome/global/about.dtd) locale/@AB_CD@/global/about.dtd (%chrome/global/about.dtd)
locale/@AB_CD@/global/aboutRights.dtd (%chrome/global/aboutRights.dtd)
locale/@AB_CD@/global/aboutRights.properties (%chrome/global/aboutRights.properties)
locale/@AB_CD@/global/appPicker.dtd (%chrome/global/appPicker.dtd) locale/@AB_CD@/global/appPicker.dtd (%chrome/global/appPicker.dtd)
locale/@AB_CD@/global/brand.dtd (generic/chrome/global/brand.dtd) locale/@AB_CD@/global/brand.dtd (generic/chrome/global/brand.dtd)
+ locale/@AB_CD@/global/browser.properties (%chrome/global/browser.properties) + locale/@AB_CD@/global/browser.properties (%chrome/global/browser.properties)