chore: remove unrequired items from about:preferences
(cherry picked from commit 6529b5e62d92d07dea243719c1078f736cd5a194)
This commit is contained in:
@@ -55,6 +55,9 @@ const WaterfoxGlue = {
|
||||
case "preferences-privacy":
|
||||
uri = "resource://waterfox/overlays/preferences-privacy.overlay";
|
||||
break;
|
||||
case "preferences-home":
|
||||
uri = "resource://waterfox/overlays/preferences-home.overlay";
|
||||
break;
|
||||
}
|
||||
let chromeManifest = new ChromeManifest(async () => {
|
||||
let res = await fetch(uri);
|
||||
@@ -114,20 +117,31 @@ const WaterfoxGlue = {
|
||||
await this.getChromeManifest("preferences-general"),
|
||||
subject
|
||||
);
|
||||
if (subject.document.getElementById("permissionsGroup")) {
|
||||
await Overlays.load(
|
||||
await this.getChromeManifest("preferences-privacy"),
|
||||
subject
|
||||
);
|
||||
subject.privacyInitialized = true;
|
||||
} else {
|
||||
if (
|
||||
!subject.document.getElementById("permissionsGroup") &&
|
||||
!subject.document.getElementById("homeContentsGroup")
|
||||
) {
|
||||
subject.setTimeout(async () => {
|
||||
await Overlays.load(
|
||||
await this.getChromeManifest("preferences-privacy"),
|
||||
subject
|
||||
);
|
||||
await Overlays.load(
|
||||
await this.getChromeManifest("preferences-home"),
|
||||
subject
|
||||
);
|
||||
subject.privacyInitialized = true;
|
||||
}, 500);
|
||||
} else {
|
||||
await Overlays.load(
|
||||
await this.getChromeManifest("preferences-privacy"),
|
||||
subject
|
||||
);
|
||||
await Overlays.load(
|
||||
await this.getChromeManifest("preferences-home"),
|
||||
subject
|
||||
);
|
||||
subject.privacyInitialized = true;
|
||||
}
|
||||
subject.initialized = true;
|
||||
}
|
||||
|
||||
@@ -12,6 +12,7 @@
|
||||
Services.scriptloader.loadSubScript("chrome://browser/content/overlays/general.js", this);
|
||||
gMainPaneOverlay.init();
|
||||
</script>
|
||||
|
||||
<vbox id="mainPrefPane">
|
||||
<!-- Tab Bar Position preferences -->
|
||||
<vbox id="tabPositionSettingsContainer" insertafter="browserContainersbox">
|
||||
|
||||
@@ -0,0 +1,10 @@
|
||||
<?xml version="1.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/. -->
|
||||
|
||||
<overlay id="preferences-overlay" xmlns:html="http://www.w3.org/1999/xhtml"
|
||||
xmlns="http://www.mozilla.org/keymaster/gatekeeper/there.is.only.xul">
|
||||
<vbox data-subcategory="topstories" delete="true" />
|
||||
<vbox data-subcategory="snippets" delete="true" />
|
||||
</overlay>
|
||||
@@ -2,9 +2,11 @@ browser.jar:
|
||||
% content browser %content/browser/ contentaccessible=yes
|
||||
* content/browser/overlays/preferences-general.xhtml (content/preferences-general.xhtml)
|
||||
content/browser/overlays/preferences-privacy.xhtml (content/preferences-privacy.xhtml)
|
||||
content/browser/overlays/preferences-home.xhtml (content/preferences-home.xhtml)
|
||||
content/browser/overlays/general.js (content/general.js)
|
||||
content/browser/overlays/privacy.js (content/privacy.js)
|
||||
|
||||
% resource waterfox %waterfox/ contentaccessible=yes
|
||||
waterfox/overlays/preferences-general.overlay (preferences-general.overlay)
|
||||
waterfox/overlays/preferences-privacy.overlay (preferences-privacy.overlay)
|
||||
waterfox/overlays/preferences-privacy.overlay (preferences-privacy.overlay)
|
||||
waterfox/overlays/preferences-home.overlay (preferences-home.overlay)
|
||||
|
||||
@@ -0,0 +1 @@
|
||||
overlay about:preferences chrome://browser/content/overlays/preferences-home.xhtml
|
||||
Reference in New Issue
Block a user