summaryrefslogtreecommitdiffstats
path: root/application/basilisk/components/preferences/in-content/privacy.js
diff options
context:
space:
mode:
authorGaming4JC <g4jc@bulletmail.org>2019-03-18 20:51:28 -0400
committerGaming4JC <g4jc@bulletmail.org>2019-03-18 20:51:28 -0400
commit1f5194b5f1deb0f36b36ed886d94ce5f8b62ca9d (patch)
tree0b09fca9ed0c1bfe73346ae1ac1a3ac68210d614 /application/basilisk/components/preferences/in-content/privacy.js
parentd0b4eb41bb6ac08171c164187bf33e03c58d4749 (diff)
downloadUXP-1f5194b5f1deb0f36b36ed886d94ce5f8b62ca9d.tar
UXP-1f5194b5f1deb0f36b36ed886d94ce5f8b62ca9d.tar.gz
UXP-1f5194b5f1deb0f36b36ed886d94ce5f8b62ca9d.tar.lz
UXP-1f5194b5f1deb0f36b36ed886d94ce5f8b62ca9d.tar.xz
UXP-1f5194b5f1deb0f36b36ed886d94ce5f8b62ca9d.zip
Issue #756 - Remove Contextual Identity from Basilisk
Diffstat (limited to 'application/basilisk/components/preferences/in-content/privacy.js')
-rw-r--r--application/basilisk/components/preferences/in-content/privacy.js88
1 files changed, 0 insertions, 88 deletions
diff --git a/application/basilisk/components/preferences/in-content/privacy.js b/application/basilisk/components/preferences/in-content/privacy.js
index eab606e36..a976fb4fa 100644
--- a/application/basilisk/components/preferences/in-content/privacy.js
+++ b/application/basilisk/components/preferences/in-content/privacy.js
@@ -5,8 +5,6 @@
Components.utils.import("resource://gre/modules/AppConstants.jsm");
Components.utils.import("resource://gre/modules/PluralForm.jsm");
-XPCOMUtils.defineLazyModuleGetter(this, "ContextualIdentityService",
- "resource://gre/modules/ContextualIdentityService.jsm");
XPCOMUtils.defineLazyModuleGetter(this, "PluralForm",
"resource://gre/modules/PluralForm.jsm");
@@ -62,59 +60,6 @@ var gPrivacyPane = {
},
/**
- * Show the Containers UI depending on the privacy.userContext.ui.enabled pref.
- */
- _initBrowserContainers: function () {
- if (!Services.prefs.getBoolPref("privacy.userContext.ui.enabled")) {
- return;
- }
-
- let link = document.getElementById("browserContainersLearnMore");
- link.href = Services.urlFormatter.formatURLPref("app.support.baseURL") + "containers";
-
- document.getElementById("browserContainersbox").hidden = false;
-
- document.getElementById("browserContainersCheckbox").checked =
- Services.prefs.getBoolPref("privacy.userContext.enabled");
- },
-
- _checkBrowserContainers: function(event) {
- let checkbox = document.getElementById("browserContainersCheckbox");
- if (checkbox.checked) {
- Services.prefs.setBoolPref("privacy.userContext.enabled", true);
- return;
- }
-
- let count = ContextualIdentityService.countContainerTabs();
- if (count == 0) {
- Services.prefs.setBoolPref("privacy.userContext.enabled", false);
- return;
- }
-
- let bundlePreferences = document.getElementById("bundlePreferences");
-
- let title = bundlePreferences.getString("disableContainersAlertTitle");
- let message = PluralForm.get(count, bundlePreferences.getString("disableContainersMsg"))
- .replace("#S", count)
- let okButton = PluralForm.get(count, bundlePreferences.getString("disableContainersOkButton"))
- .replace("#S", count)
- let cancelButton = bundlePreferences.getString("disableContainersButton2");
-
- let buttonFlags = (Ci.nsIPrompt.BUTTON_TITLE_IS_STRING * Ci.nsIPrompt.BUTTON_POS_0) +
- (Ci.nsIPrompt.BUTTON_TITLE_IS_STRING * Ci.nsIPrompt.BUTTON_POS_1);
-
- let rv = Services.prompt.confirmEx(window, title, message, buttonFlags,
- okButton, cancelButton, null, null, {});
- if (rv == 0) {
- ContextualIdentityService.closeAllContainerTabs();
- Services.prefs.setBoolPref("privacy.userContext.enabled", false);
- return;
- }
-
- checkbox.checked = true;
- },
-
- /**
* Sets up the UI for the number of days of history to keep, and updates the
* label of the "Clear Now..." button.
*/
@@ -136,7 +81,6 @@ var gPrivacyPane = {
this._initTrackingProtectionPBM();
#endif
this._initAutocomplete();
- this._initBrowserContainers();
setEventListener("privacy.sanitize.sanitizeOnShutdown", "change",
gPrivacyPane._updateSanitizeSettingsButton);
@@ -184,10 +128,6 @@ var gPrivacyPane = {
setEventListener("changeBlockListPBM", "command",
gPrivacyPane.showBlockLists);
#endif
- setEventListener("browserContainersCheckbox", "command",
- gPrivacyPane._checkBrowserContainers);
- setEventListener("browserContainersSettings", "command",
- gPrivacyPane.showContainerSettings);
},
#ifdef MOZ_SAFE_BROWSING
@@ -489,13 +429,6 @@ var gPrivacyPane = {
},
#endif
- /**
- * Displays container panel for customising and adding containers.
- */
- showContainerSettings() {
- gotoPref("containers");
- },
-
#ifdef MOZ_SAFE_BROWSING
/**
* Displays the available block lists for tracking protection.
@@ -702,25 +635,4 @@ var gPrivacyPane = {
settingsButton.disabled = !sanitizeOnShutdownPref.value;
},
-
- // CONTAINERS
-
- /*
- * preferences:
- *
- * privacy.userContext.enabled
- * - true if containers is enabled
- */
-
- /**
- * Enables/disables the Settings button used to configure containers
- */
- readBrowserContainersCheckbox: function ()
- {
- var pref = document.getElementById("privacy.userContext.enabled");
- var settings = document.getElementById("browserContainersSettings");
-
- settings.disabled = !pref.value;
- }
-
};