mirror of
https://gitlab.winehq.org/wine/wine-gecko.git
synced 2024-09-13 09:24:08 -07:00
Bug 775824 - Use the new Permission Manager API in AlarmManager. r=sicking
This commit is contained in:
parent
cbf499a219
commit
c4aa2e4999
@ -134,8 +134,7 @@ AlarmsManager.prototype = {
|
||||
let principal = aWindow.document.nodePrincipal;
|
||||
let secMan = Cc["@mozilla.org/scriptsecuritymanager;1"].getService(Ci.nsIScriptSecurityManager);
|
||||
|
||||
let perm = principal == secMan.getSystemPrincipal() ?
|
||||
Ci.nsIPermissionManager.ALLOW_ACTION : Services.perms.testExactPermission(principal.URI, "alarms");
|
||||
let perm = Services.perms.testExactPermissionFromPrincipal(principal, "alarms");
|
||||
|
||||
// Only pages with perm set can use the alarms.
|
||||
this.hasPrivileges = perm == Ci.nsIPermissionManager.ALLOW_ACTION;
|
||||
|
Loading…
Reference in New Issue
Block a user