mirror of
https://gitlab.winehq.org/wine/wine-gecko.git
synced 2024-09-13 09:24:08 -07:00
Bug 1112189 - Additional telemetry for tracking protection shield. r=mfinkle
--HG-- extra : rebase_source : eda2d69c36118cc93540ab0bed934d53c9de0c03
This commit is contained in:
parent
71f74038cd
commit
8bc141ec58
@ -349,6 +349,8 @@ var BrowserApp = {
|
||||
#endif
|
||||
#ifdef NIGHTLY_BUILD
|
||||
WebcompatReporter.init();
|
||||
Telemetry.addData("TRACKING_PROTECTION_ENABLED",
|
||||
Services.prefs.getBoolPref("privacy.trackingprotection.enabled"));
|
||||
#endif
|
||||
} catch(ex) { console.log(ex); }
|
||||
}, false);
|
||||
@ -6788,15 +6790,18 @@ var IdentityHandler = {
|
||||
|
||||
getTrackingMode: function getTrackingMode(aState) {
|
||||
if (aState & Ci.nsIWebProgressListener.STATE_BLOCKED_TRACKING_CONTENT) {
|
||||
Telemetry.addData("TRACKING_PROTECTION_SHIELD", 2);
|
||||
return this.TRACKING_MODE_CONTENT_BLOCKED;
|
||||
}
|
||||
|
||||
// Only show an indicator for loaded tracking content if the pref to block it is enabled
|
||||
if ((aState & Ci.nsIWebProgressListener.STATE_LOADED_TRACKING_CONTENT) &&
|
||||
Services.prefs.getBoolPref("privacy.trackingprotection.enabled")) {
|
||||
Telemetry.addData("TRACKING_PROTECTION_SHIELD", 1);
|
||||
return this.TRACKING_MODE_CONTENT_LOADED;
|
||||
}
|
||||
|
||||
Telemetry.addData("TRACKING_PROTECTION_SHIELD", 0);
|
||||
return this.TRACKING_MODE_UNKNOWN;
|
||||
},
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user