mirror of
https://github.com/mozilla/gecko-dev.git
synced 2024-10-08 19:04:45 +00:00
Bug 1175920 - Add a checkbox to the in-content Privacy preferences to toggle TP in Private Browsing. r=jaws
This commit is contained in:
parent
2940d9fe61
commit
2677afc219
@ -34,6 +34,16 @@ var gPrivacyPane = {
|
||||
},
|
||||
#endif
|
||||
|
||||
/**
|
||||
* Linkify the Learn More link of the Private Browsing Mode Tracking
|
||||
* Protection UI.
|
||||
*/
|
||||
_initTrackingProtectionPBM: function () {
|
||||
let link = document.getElementById("trackingProtectionPBMLearnMore");
|
||||
let url = Services.urlFormatter.formatURLPref("app.support.baseURL") + "tracking-protection-pbm";
|
||||
link.setAttribute("href", url);
|
||||
},
|
||||
|
||||
/**
|
||||
* Initialize autocomplete to ensure prefs are in sync.
|
||||
*/
|
||||
@ -73,6 +83,7 @@ var gPrivacyPane = {
|
||||
#ifdef NIGHTLY_BUILD
|
||||
this._initTrackingProtection();
|
||||
#endif
|
||||
this._initTrackingProtectionPBM();
|
||||
this._initAutocomplete();
|
||||
|
||||
setEventListener("privacy.sanitize.sanitizeOnShutdown", "change",
|
||||
|
@ -16,6 +16,9 @@
|
||||
<preference id="privacy.trackingprotection.enabled"
|
||||
name="privacy.trackingprotection.enabled"
|
||||
type="bool"/>
|
||||
<preference id="privacy.trackingprotection.pbmode.enabled"
|
||||
name="privacy.trackingprotection.pbmode.enabled"
|
||||
type="bool"/>
|
||||
|
||||
<!-- XXX button prefs -->
|
||||
<preference id="pref.privacy.disable_button.cookie_exceptions"
|
||||
@ -83,30 +86,12 @@
|
||||
<!-- Tracking -->
|
||||
<groupbox id="trackingGroup" data-category="panePrivacy" hidden="true" align="start">
|
||||
<caption><label>&tracking.label;</label></caption>
|
||||
<vbox id="trackingprotectionbox" hidden="true">
|
||||
<hbox align="center">
|
||||
<checkbox id="trackingProtection"
|
||||
preference="privacy.trackingprotection.enabled"
|
||||
accesskey="&trackingProtection.accesskey;"
|
||||
label="&trackingProtection.label;" />
|
||||
<image id="trackingProtectionImage"/>
|
||||
</hbox>
|
||||
<hbox align="center"
|
||||
class="indent">
|
||||
<label id="trackingProtectionLearnMore"
|
||||
class="text-link"
|
||||
value="&trackingProtectionLearnMore.label;"/>
|
||||
</hbox>
|
||||
</vbox>
|
||||
<vbox>
|
||||
<hbox align="center">
|
||||
<checkbox id="privacyDoNotTrackCheckbox"
|
||||
label="&dntTrackingNotOkay.label2;"
|
||||
accesskey="&dntTrackingNotOkay.accesskey;"
|
||||
preference="privacy.donottrackheader.enabled"/>
|
||||
</hbox>
|
||||
<hbox align="center"
|
||||
class="indent">
|
||||
<label id="doNotTrackInfo"
|
||||
class="text-link"
|
||||
href="https://www.mozilla.org/dnt">
|
||||
@ -114,6 +99,28 @@
|
||||
</label>
|
||||
</hbox>
|
||||
</vbox>
|
||||
<vbox id="trackingprotectionbox" hidden="true">
|
||||
<hbox align="center">
|
||||
<checkbox id="trackingProtection"
|
||||
preference="privacy.trackingprotection.enabled"
|
||||
accesskey="&trackingProtection.accesskey;"
|
||||
label="&trackingProtection.label;" />
|
||||
<label id="trackingProtectionLearnMore"
|
||||
class="text-link"
|
||||
value="&trackingProtectionLearnMore.label;"/>
|
||||
</hbox>
|
||||
</vbox>
|
||||
<vbox id="trackingprotectionpbmbox">
|
||||
<hbox align="center">
|
||||
<checkbox id="trackingProtectionPBM"
|
||||
preference="privacy.trackingprotection.pbmode.enabled"
|
||||
accesskey="&trackingProtectionPBM.accesskey;"
|
||||
label="&trackingProtectionPBM.label;" />
|
||||
<label id="trackingProtectionPBMLearnMore"
|
||||
class="text-link"
|
||||
value="&trackingProtectionPBMLearnMore.label;"/>
|
||||
</hbox>
|
||||
</vbox>
|
||||
</groupbox>
|
||||
|
||||
<!-- History -->
|
||||
|
@ -9,6 +9,9 @@
|
||||
<!ENTITY trackingProtection.label "Prevent sites from tracking me">
|
||||
<!ENTITY trackingProtection.accesskey "m">
|
||||
<!ENTITY trackingProtectionLearnMore.label "Learn more">
|
||||
<!ENTITY trackingProtectionPBM.label "Prevent sites from tracking my online activity in Private Windows">
|
||||
<!ENTITY trackingProtectionPBM.accesskey "m">
|
||||
<!ENTITY trackingProtectionPBMLearnMore.label "Learn more">
|
||||
<!ENTITY doNotTrackInfo.label "Learn More">
|
||||
|
||||
<!ENTITY history.label "History">
|
||||
|
@ -267,16 +267,8 @@ description > html|a {
|
||||
-moz-margin-start: 33px;
|
||||
}
|
||||
|
||||
#trackingProtectionImage {
|
||||
width: 16px;
|
||||
height: 16px;
|
||||
list-style-image: url(chrome://browser/skin/bad-content-blocked-16.png);
|
||||
}
|
||||
|
||||
@media (min-resolution: 2dppx) {
|
||||
#trackingProtectionImage {
|
||||
list-style-image: url(chrome://browser/skin/bad-content-blocked-16@2x.png);
|
||||
}
|
||||
.text-link {
|
||||
margin-bottom: 0;
|
||||
}
|
||||
|
||||
#showUpdateHistory {
|
||||
|
Loading…
Reference in New Issue
Block a user