Bug 1675814 - Remove global.dtd as unused. r=flod,geckoview-reviewers,owlish

Now that it's no longer used, the global.dtd file and its single remaining string `locale.dir` may be removed.

A test specifically targeting this is also removed as obsolete.

Differential Revision: https://phabricator.services.mozilla.com/D157797
This commit is contained in:
Eemeli Aro 2022-10-07 18:40:28 +00:00
parent 1662ea09fa
commit f0a0871780
12 changed files with 0 additions and 120 deletions

View File

@ -1,5 +0,0 @@
<!-- This Source Code Form is subject to the terms of the Mozilla Public
- License, v. 2.0. If a copy of the MPL was not distributed with this
- file, You can obtain one at http://mozilla.org/MPL/2.0/. -->
<!ENTITY locale.dir "ltr">

View File

@ -11,7 +11,6 @@
locale/@AB_CD@/global/xul.properties (%chrome/layout/xul.properties)
locale/@AB_CD@/global/printing.properties (%chrome/layout/printing.properties)
locale/@AB_CD@/global/layout_errors.properties (%chrome/layout/layout_errors.properties)
locale/@AB_CD@/global/global.dtd (%chrome/global.dtd)
locale/@AB_CD@/global/appstrings.properties (%chrome/appstrings.properties)
locale/@AB_CD@/global/global-strres.properties (%chrome/global-strres.properties)
locale/@AB_CD@/global/nsWebBrowserPersist.properties (%chrome/nsWebBrowserPersist.properties)

View File

@ -55,7 +55,6 @@ def test(mod, path, entity=None):
if mod == "dom":
# keep this file list in sync with jar.mn
if path in (
"chrome/global.dtd",
"chrome/accessibility/AccessFu.properties",
"chrome/dom/dom.properties",
):

View File

@ -23,7 +23,6 @@ relativesrcdir toolkit/locales:
# overrides for dom l10n, also for en-US
# keep this file list in sync with filter.py
relativesrcdir dom/locales:
locale/@AB_CD@/browser/overrides/global.dtd (%chrome/global.dtd)
locale/@AB_CD@/browser/overrides/AccessFu.properties (%chrome/accessibility/AccessFu.properties)
locale/@AB_CD@/browser/overrides/dom/dom.properties (%chrome/dom/dom.properties)

View File

@ -125,10 +125,6 @@ exclude-multi-locale = [
l10n = "{l}mobile/android/**"
# hand-picked paths from toolkit, keep in sync with jar.mn
[[paths]]
reference = "dom/locales/en-US/chrome/global.dtd"
l10n = "{l}dom/chrome/global.dtd"
[[paths]]
reference = "dom/locales/en-US/chrome/accessibility/AccessFu.properties"
l10n = "{l}dom/chrome/accessibility/AccessFu.properties"

View File

@ -56,7 +56,6 @@ def test(mod, path, entity=None):
if mod == "dom":
# keep this file list in sync with jar.mn
if path in (
"chrome/global.dtd",
"chrome/accessibility/AccessFu.properties",
"chrome/dom/dom.properties",
):

View File

@ -145,11 +145,6 @@ with Files("tests/chrome/*418874*"):
with Files("tests/chrome/*429723*"):
BUG_COMPONENT = ("Toolkit", "Find Toolbar")
with Files("tests/chrome/*437844*"):
BUG_COMPONENT = ("Toolkit", "General")
with Files("tests/chrome/rtlchrome/**"):
BUG_COMPONENT = ("Toolkit", "General")
with Files("tests/chrome/*451540*"):
BUG_COMPONENT = ("Toolkit", "Find Toolbar")

View File

@ -49,9 +49,6 @@ support-files =
window_subframe_origin.xhtml
window_tooltip.xhtml
xul_selectcontrol.js
rtlchrome/rtl.css
rtlchrome/rtl.dtd
rtlchrome/rtl.manifest
prefs =
gfx.font_rendering.fallback.async=false
widget.non-native-theme.enabled=false
@ -84,8 +81,6 @@ skip-if = os == 'linux' # Bug 1264604
[test_bug409624.xhtml]
[test_bug418874.xhtml]
[test_bug429723.xhtml]
[test_bug437844.xhtml]
skip-if = (verify && debug && (os == 'mac' || os == 'win'))
[test_bug451540.xhtml]
support-files = bug451540_window.xhtml
[test_bug457632.xhtml]

View File

@ -1,2 +0,0 @@
/* Imitate RTL UI */
window { direction: rtl; }

View File

@ -1 +0,0 @@
<!ENTITY locale.dir "rtl">

View File

@ -1,5 +0,0 @@
content rtlchrome /
# Override intl.css with our own CSS file
override chrome://global/locale/intl.css chrome://rtlchrome/rtl.css
override chrome://global/locale/global.dtd chrome://rtlchrome/rtl.dtd

View File

@ -1,89 +0,0 @@
<?xml version="1.0"?>
<?xml-stylesheet href="chrome://global/skin" type="text/css"?>
<?xml-stylesheet
href="chrome://mochikit/content/tests/SimpleTest/test.css"
type="text/css"?>
<!--
https://bugzilla.mozilla.org/show_bug.cgi?id=437844
https://bugzilla.mozilla.org/show_bug.cgi?id=348233
-->
<window title="Mozilla Bug 437844 and Bug 348233"
xmlns="http://www.mozilla.org/keymaster/gatekeeper/there.is.only.xul">
<script type="application/javascript"
src="chrome://mochikit/content/tests/SimpleTest/SimpleTest.js"></script>
<script type="application/javascript"
src="chrome://mochikit/content/chrome-harness.js"></script>
<script type="application/javascript"
src="RegisterUnregisterChrome.js"></script>
<body xmlns="http://www.w3.org/1999/xhtml">
<a target="_blank"
href="https://bugzilla.mozilla.org/show_bug.cgi?id=437844">
Mozilla Bug 437844
</a>
<a target="_blank"
href="https://bugzilla.mozilla.org/show_bug.cgi?id=348233">
Mozilla Bug 348233
</a>
<p id="display"></p>
<div id="content" style="display: none">
</div>
<pre id="test">
</pre>
</body>
<script class="testbody" type="application/javascript">
<![CDATA[
SimpleTest.expectAssertions(0, 58);
/** Test for Bug 437844 and Bug 348233 **/
SimpleTest.waitForExplicitFinish();
let prefs = SpecialPowers.Services.prefs;
prefs.setCharPref("intl.l10n.pseudo", "bidi");
let rootDir = getRootDirectory(window.location.href);
let manifest = rootDir + "rtlchrome/rtl.manifest";
//copy rtlchrome to profile/rtlchrome and generate .manifest
let filePath = chromeURIToFile(manifest);
let tempProfileDir = copyDirToTempProfile(filePath.path, 'rtlchrome');
if (tempProfileDir.path.lastIndexOf('\\') >= 0) {
manifest = "content rtlchrome /" + tempProfileDir.path.replace(/\\/g, '/') + "\n";
} else {
manifest = "content rtlchrome " + tempProfileDir.path + "\n";
}
manifest += "override chrome://global/locale/intl.css chrome://rtlchrome/content/rtlchrome/rtl.css\n";
manifest += "override chrome://global/locale/global.dtd chrome://rtlchrome/content/rtlchrome/rtl.dtd\n";
let cleanupFunc = createManifestTemporarily(tempProfileDir, manifest);
// Load about:plugins in an iframe
let frame = document.createXULElement("iframe");
frame.setAttribute("src", "about:plugins");
frame.addEventListener("load", function () {
is(frame.contentDocument.dir, "rtl", "about:plugins should be RTL in RTL locales");
// eslint-disable-next-line no-unused-vars
let tmpd = SpecialPowers.Services.dirsvc.get("ProfD", Ci.nsIFile);
frame = document.createXULElement("iframe");
frame.setAttribute("src", "file://" + tmpd.path); // a file:// URI, bug 348233
frame.addEventListener("load", function () {
is(frame.contentDocument.body.dir, "rtl", "file:// listings should be RTL in RTL locales");
cleanupFunc();
prefs.clearUserPref("intl.l10n.pseudo");
SimpleTest.finish();
});
document.documentElement.appendChild(frame);
}, { once: true });
document.documentElement.appendChild(frame);
]]>
</script>
</window>