Merge f-t to m-c, a=merge

This commit is contained in:
Phil Ringnalda 2016-09-05 13:06:35 -07:00
commit 55c3c1efd5
2 changed files with 26 additions and 0 deletions

View File

@ -7411,6 +7411,23 @@ var gIdentityHandler = {
SitePermissions.remove(gBrowser.currentURI, aPermission.id);
this._permissionJustRemoved = true;
this.updatePermissionHint();
// Set telemetry values for clearing a permission
let histogram = Services.telemetry.getKeyedHistogramById("WEB_PERMISSION_CLEARED");
let permissionType = 0;
if (aPermission.state == SitePermissions.ALLOW) {
// 1 : clear permanently allowed permission
permissionType = 1;
} else if (aPermission.state == SitePermissions.BLOCK) {
// 2 : clear permanently blocked permission
permissionType = 2;
}
// 3 : TODO clear temporary allowed permission
// 4 : TODO clear temporary blocked permission
histogram.add("(all)", permissionType);
histogram.add(aPermission.id, permissionType);
});
container.appendChild(img);

View File

@ -10203,5 +10203,14 @@
"bug_numbers": [1296606],
"kind": "count",
"description": "Number of named profiles."
},
"WEB_PERMISSION_CLEARED": {
"alert_emails": ["firefox-dev@mozilla.org"],
"bug_numbers": [1286118],
"expires_in_version": "55",
"kind": "enumerated",
"keyed": true,
"n_values": 6,
"description": "Number of revoke actions on permissions in the control center, keyed by permission id. Values represent the permission type that was revoked. (0=unknown, 1=permanently allowed, 2=permanently blocked, 3=temporarily allowed, 4=temporarily blocked)"
}
}