Backed out 3 changesets (bug 1830623) for mochitest failures on test_navigator.html . CLOSED TREE
Backed out changeset e62ba02af50f (bug 1830623) Backed out changeset 2667feba3922 (bug 1830623) Backed out changeset 320a740f003c (bug 1830623)
This commit is contained in:
@@ -1014,11 +1014,6 @@ pref("privacy.temporary_permission_expire_time_ms", 3600000);
|
||||
// See bug 791594
|
||||
pref("privacy.authPromptSpoofingProtection", true);
|
||||
|
||||
// Enable GPC if the user turns it on in about:preferences
|
||||
#ifdef NIGHTLY_BUILD
|
||||
pref("privacy.globalprivacycontrol.functionality.enabled", true);
|
||||
#endif
|
||||
|
||||
pref("network.proxy.share_proxy_settings", false); // use the same proxy settings for all protocols
|
||||
|
||||
// simple gestures support
|
||||
@@ -1526,7 +1521,6 @@ pref("services.sync.prefs.sync.privacy.clearOnShutdown.offlineApps", true);
|
||||
pref("services.sync.prefs.sync.privacy.clearOnShutdown.sessions", true);
|
||||
pref("services.sync.prefs.sync.privacy.clearOnShutdown.siteSettings", true);
|
||||
pref("services.sync.prefs.sync.privacy.donottrackheader.enabled", true);
|
||||
pref("services.sync.prefs.sync.privacy.globalprivacycontrol.enabled", true);
|
||||
pref("services.sync.prefs.sync.privacy.sanitize.sanitizeOnShutdown", true);
|
||||
pref("services.sync.prefs.sync.privacy.trackingprotection.enabled", true);
|
||||
pref("services.sync.prefs.sync.privacy.trackingprotection.cryptomining.enabled", true);
|
||||
|
||||
@@ -328,21 +328,12 @@
|
||||
</vbox>
|
||||
</radiogroup>
|
||||
</vbox>
|
||||
<vbox id="nonTechnicalPrivacyBox">
|
||||
<hbox id="globalPrivacyControlBox" flex="1" align="center" hidden="true">
|
||||
<checkbox id="globalPrivacyControlCheckbox"
|
||||
class="tail-with-learn-more"
|
||||
preference="privacy.globalprivacycontrol.enabled"
|
||||
data-l10n-id="global-privacy-control-description" />
|
||||
<html:a is="moz-support-link"
|
||||
id="globalPrivacyControlLearnMoreLink"
|
||||
support-page="global-privacy-control" />
|
||||
</hbox>
|
||||
<vbox id="legacyDoNotTrackBox">
|
||||
<vbox id="doNotTrackLearnMoreBox">
|
||||
<label>
|
||||
<label class="tail-with-learn-more" data-l10n-id="do-not-track-description" id="doNotTrackDesc"></label>
|
||||
<html:a is="moz-support-link"
|
||||
class="learnMore"
|
||||
data-l10n-id="do-not-track-learn-more"
|
||||
support-page="how-do-i-turn-do-not-track-feature"
|
||||
/>
|
||||
</label>
|
||||
@@ -351,16 +342,6 @@
|
||||
<radio value="false" data-l10n-id="do-not-track-option-default-content-blocking-known"/>
|
||||
</radiogroup>
|
||||
</vbox>
|
||||
<hbox id="doNotTrackBox" flex="1" align="center">
|
||||
<checkbox id="doNotTrackCheckbox"
|
||||
class="tail-with-learn-more"
|
||||
preference="privacy.donottrackheader.enabled"
|
||||
data-l10n-id="do-not-track-description2" />
|
||||
<html:a is="moz-support-link"
|
||||
id="doNotTrackLearnMoreLink"
|
||||
support-page="how-do-i-turn-do-not-track-feature" />
|
||||
</hbox>
|
||||
</vbox>
|
||||
</vbox>
|
||||
</groupbox>
|
||||
|
||||
|
||||
@@ -148,9 +148,6 @@ Preferences.addAll([
|
||||
// Do not track
|
||||
{ id: "privacy.donottrackheader.enabled", type: "bool" },
|
||||
|
||||
// Global Privacy Control
|
||||
{ id: "privacy.globalprivacycontrol.enabled", type: "bool" },
|
||||
|
||||
// Media
|
||||
{ id: "media.autoplay.default", type: "int" },
|
||||
|
||||
@@ -995,7 +992,6 @@ var gPrivacyPane = {
|
||||
|
||||
this._pane = document.getElementById("panePrivacy");
|
||||
|
||||
this._initGlobalPrivacyControlUI();
|
||||
this._initPasswordGenerationUI();
|
||||
this._initRelayIntegrationUI();
|
||||
this._initMasterPasswordUI();
|
||||
@@ -2888,22 +2884,6 @@ var gPrivacyPane = {
|
||||
});
|
||||
},
|
||||
|
||||
/**
|
||||
* Set up the initial state for the GPC/DNT UI.
|
||||
* The GPC part should only appear if the functionality is
|
||||
* enabled.
|
||||
*/
|
||||
_initGlobalPrivacyControlUI() {
|
||||
let gpcEnabledPrefValue = Services.prefs.getBoolPref(
|
||||
"privacy.globalprivacycontrol.functionality.enabled",
|
||||
false
|
||||
);
|
||||
document.getElementById("globalPrivacyControlBox").hidden =
|
||||
!gpcEnabledPrefValue;
|
||||
document.getElementById("doNotTrackBox").hidden = !gpcEnabledPrefValue;
|
||||
document.getElementById("legacyDoNotTrackBox").hidden = gpcEnabledPrefValue;
|
||||
},
|
||||
|
||||
/**
|
||||
* Set up the initial state for the password generation UI.
|
||||
* It will be hidden unless the .available pref is true
|
||||
|
||||
@@ -98,7 +98,6 @@ skip-if = true
|
||||
[browser_privacy_cookieBannerHandling.js]
|
||||
[browser_privacy_dnsoverhttps.js]
|
||||
[browser_privacy_firefoxSuggest.js]
|
||||
[browser_privacy_gpc.js]
|
||||
[browser_privacy_passwordGenerationAndAutofill.js]
|
||||
[browser_privacy_quickactions.js]
|
||||
[browser_privacy_relayIntegration.js]
|
||||
|
||||
@@ -1,182 +0,0 @@
|
||||
/* Any copyright is dedicated to the Public Domain.
|
||||
* https://creativecommons.org/publicdomain/zero/1.0/ */
|
||||
|
||||
// This file tests the Privacy pane's Cookie Banner Handling UI.
|
||||
|
||||
"use strict";
|
||||
|
||||
const FEATURE_PREF = "privacy.globalprivacycontrol.functionality.enabled";
|
||||
const MODE_PREF = "privacy.globalprivacycontrol.enabled";
|
||||
const DNT_PREF = "privacy.donottrackheader.enabled";
|
||||
|
||||
const SECTION_ID = "nonTechnicalPrivacyBox";
|
||||
const GPC_ID = "globalPrivacyControlBox";
|
||||
const GPC_CHECKBOX_ID = "globalPrivacyControlCheckbox";
|
||||
const OLD_DNT_ID = "legacyDoNotTrackBox";
|
||||
const NEW_DNT_ID = "doNotTrackBox";
|
||||
const DNT_CHECKBOX_ID = "doNotTrackCheckbox";
|
||||
|
||||
// Test the section is hidden on page load if the feature pref is disabled.
|
||||
// Also make sure we keep the old DNT interface.
|
||||
add_task(async function test_section_hidden_when_feature_flag_disabled() {
|
||||
await SpecialPowers.pushPrefEnv({
|
||||
set: [
|
||||
[FEATURE_PREF, false],
|
||||
[MODE_PREF, false],
|
||||
],
|
||||
});
|
||||
|
||||
await BrowserTestUtils.withNewTab(
|
||||
{ gBrowser, url: "about:preferences#privacy" },
|
||||
async function (browser) {
|
||||
let gpc = browser.contentDocument.getElementById(GPC_ID);
|
||||
is_element_hidden(gpc, "#globalPrivacyControlBox is hidden");
|
||||
let new_dnt = browser.contentDocument.getElementById(NEW_DNT_ID);
|
||||
is_element_hidden(new_dnt, "#doNotTrackBox is hidden");
|
||||
let old_dnt = browser.contentDocument.getElementById(OLD_DNT_ID);
|
||||
is_element_visible(old_dnt, "#doNotTrackBox is shown");
|
||||
}
|
||||
);
|
||||
|
||||
await SpecialPowers.popPrefEnv();
|
||||
});
|
||||
|
||||
// Test the section is shown on page load if the feature pref is enabled.
|
||||
// Also make sure we show the new DNT interface.
|
||||
add_task(async function test_section_shown_when_feature_flag_enabled() {
|
||||
await SpecialPowers.pushPrefEnv({
|
||||
set: [
|
||||
[FEATURE_PREF, true],
|
||||
[MODE_PREF, false],
|
||||
],
|
||||
});
|
||||
|
||||
await BrowserTestUtils.withNewTab(
|
||||
{ gBrowser, url: "about:preferences#privacy" },
|
||||
async function (browser) {
|
||||
let gpc = browser.contentDocument.getElementById(GPC_ID);
|
||||
is_element_visible(gpc, "#globalPrivacyControlBox is shown");
|
||||
let new_dnt = browser.contentDocument.getElementById(NEW_DNT_ID);
|
||||
is_element_visible(new_dnt, "#doNotTrackBox is shown");
|
||||
let old_dnt = browser.contentDocument.getElementById(OLD_DNT_ID);
|
||||
is_element_hidden(old_dnt, "#doNotTrackBox is hidden");
|
||||
}
|
||||
);
|
||||
|
||||
await SpecialPowers.popPrefEnv();
|
||||
});
|
||||
|
||||
// Test the checkbox is unchecked in DISABLED mode.
|
||||
add_task(async function test_checkbox_unchecked_disabled_mode() {
|
||||
await SpecialPowers.pushPrefEnv({
|
||||
set: [
|
||||
[FEATURE_PREF, true],
|
||||
[MODE_PREF, false],
|
||||
],
|
||||
});
|
||||
|
||||
await BrowserTestUtils.withNewTab(
|
||||
{ gBrowser, url: "about:preferences#privacy" },
|
||||
async function (browser) {
|
||||
let checkbox = browser.contentDocument.getElementById(GPC_CHECKBOX_ID);
|
||||
ok(!checkbox.checked, "checkbox is not checked in DISABLED mode");
|
||||
}
|
||||
);
|
||||
|
||||
await SpecialPowers.popPrefEnv();
|
||||
});
|
||||
|
||||
// Test that toggling the checkbox toggles the mode pref value as expected
|
||||
add_task(async function test_checkbox_modifies_prefs() {
|
||||
await SpecialPowers.pushPrefEnv({
|
||||
set: [
|
||||
[FEATURE_PREF, true],
|
||||
[MODE_PREF, false],
|
||||
],
|
||||
});
|
||||
|
||||
await BrowserTestUtils.withNewTab(
|
||||
{ gBrowser, url: "about:preferences#privacy" },
|
||||
async function (browser) {
|
||||
let gpc_checkbox =
|
||||
browser.contentDocument.getElementById(GPC_CHECKBOX_ID);
|
||||
let dnt_checkbox =
|
||||
browser.contentDocument.getElementById(DNT_CHECKBOX_ID);
|
||||
let section = browser.contentDocument.getElementById(SECTION_ID);
|
||||
|
||||
section.scrollIntoView();
|
||||
|
||||
Assert.ok(
|
||||
!gpc_checkbox.checked && !dnt_checkbox.checked,
|
||||
"initially, the checkbox should be unchecked"
|
||||
);
|
||||
|
||||
await BrowserTestUtils.synthesizeMouseAtCenter(
|
||||
"#" + GPC_CHECKBOX_ID,
|
||||
{},
|
||||
browser
|
||||
);
|
||||
Assert.ok(
|
||||
gpc_checkbox.checked && !dnt_checkbox.checked,
|
||||
"gpc checkbox should be checked"
|
||||
);
|
||||
Assert.equal(
|
||||
true,
|
||||
Services.prefs.getBoolPref(MODE_PREF),
|
||||
"GPC should be on after checking the checkbox"
|
||||
);
|
||||
Assert.equal(
|
||||
false,
|
||||
Services.prefs.getBoolPref(DNT_PREF),
|
||||
"DNT should still be disabled after checking the checkbox"
|
||||
);
|
||||
|
||||
await BrowserTestUtils.synthesizeMouseAtCenter(
|
||||
"#" + DNT_CHECKBOX_ID,
|
||||
{},
|
||||
browser
|
||||
);
|
||||
Assert.ok(
|
||||
gpc_checkbox.checked && dnt_checkbox.checked,
|
||||
"both checkboxes are enabled"
|
||||
);
|
||||
Assert.equal(
|
||||
true,
|
||||
Services.prefs.getBoolPref(MODE_PREF),
|
||||
"GPC should still be on after checking the DNT checkbox"
|
||||
);
|
||||
Assert.equal(
|
||||
true,
|
||||
Services.prefs.getBoolPref(DNT_PREF),
|
||||
"DNT should still be enabled after checking the checkbox"
|
||||
);
|
||||
|
||||
await BrowserTestUtils.synthesizeMouseAtCenter(
|
||||
"#" + DNT_CHECKBOX_ID,
|
||||
{},
|
||||
browser
|
||||
);
|
||||
await BrowserTestUtils.synthesizeMouseAtCenter(
|
||||
"#" + GPC_CHECKBOX_ID,
|
||||
{},
|
||||
browser
|
||||
);
|
||||
Assert.ok(
|
||||
!gpc_checkbox.checked && !dnt_checkbox.checked,
|
||||
"both checkboxes are disabled"
|
||||
);
|
||||
Assert.equal(
|
||||
false,
|
||||
Services.prefs.getBoolPref(MODE_PREF),
|
||||
"GPC should be unchecked"
|
||||
);
|
||||
Assert.equal(
|
||||
false,
|
||||
Services.prefs.getBoolPref(DNT_PREF),
|
||||
"DNT should be unchecked"
|
||||
);
|
||||
}
|
||||
);
|
||||
|
||||
await SpecialPowers.popPrefEnv();
|
||||
});
|
||||
@@ -3,19 +3,12 @@
|
||||
# file, You can obtain one at http://mozilla.org/MPL/2.0/.
|
||||
|
||||
do-not-track-description = Send websites a “Do Not Track” signal that you don’t want to be tracked
|
||||
do-not-track-description2 =
|
||||
.label = Send websites a “Do Not Track” request
|
||||
.accesskey = d
|
||||
do-not-track-learn-more = Learn more
|
||||
do-not-track-option-default-content-blocking-known =
|
||||
.label = Only when { -brand-short-name } is set to block known trackers
|
||||
do-not-track-option-always =
|
||||
.label = Always
|
||||
|
||||
global-privacy-control-description =
|
||||
.label = Tell websites not to sell or share my data
|
||||
.accesskey = s
|
||||
|
||||
settings-page-title = Settings
|
||||
|
||||
# This is used to determine the width of the search field in about:preferences,
|
||||
|
||||
@@ -529,7 +529,7 @@ a[is="moz-support-link"]:not(.sidebar-footer-link) {
|
||||
margin-block: 0 4px;
|
||||
}
|
||||
|
||||
#nonTechnicalPrivacyBox {
|
||||
#doNotTrackLearnMoreBox {
|
||||
margin-top: 32px;
|
||||
}
|
||||
|
||||
|
||||
@@ -19,6 +19,7 @@ export var Preferences = {
|
||||
["panePrivacy", clearRecentHistoryDialog],
|
||||
["panePrivacy", certManager],
|
||||
["panePrivacy", deviceManager],
|
||||
["panePrivacy", DNTDialog],
|
||||
["paneSync"],
|
||||
];
|
||||
|
||||
@@ -124,6 +125,23 @@ async function cacheGroup(aBrowser) {
|
||||
);
|
||||
}
|
||||
|
||||
async function DNTDialog(aBrowser) {
|
||||
return aBrowser.ownerGlobal.SpecialPowers.spawn(
|
||||
aBrowser,
|
||||
[],
|
||||
async function () {
|
||||
const button = content.document.getElementById("doNotTrackSettings");
|
||||
if (!button) {
|
||||
return {
|
||||
todo: "The dialog may have exited before we could click the button",
|
||||
};
|
||||
}
|
||||
button.click();
|
||||
return undefined;
|
||||
}
|
||||
);
|
||||
}
|
||||
|
||||
async function connectionDialog(aBrowser) {
|
||||
await aBrowser.ownerGlobal.SpecialPowers.spawn(
|
||||
aBrowser,
|
||||
|
||||
@@ -8,7 +8,6 @@ var supportedProps = [
|
||||
"appCodeName",
|
||||
"appName",
|
||||
"appVersion",
|
||||
{ name: "globalPrivacyControl", isNightly: true },
|
||||
"platform",
|
||||
"product",
|
||||
"userAgent",
|
||||
|
||||
Reference in New Issue
Block a user