зеркало из https://github.com/mozilla/gecko-dev.git
Bug 1173523 - Part 9: Update pageinfo to use the new API for nsIPermission, r=florian
This commit is contained in:
Родитель
3358737163
Коммит
1a566f38c0
|
@ -1117,8 +1117,9 @@ var imagePermissionObserver = {
|
|||
var row = getSelectedRow(imageTree);
|
||||
var item = gImageView.data[row][COL_IMAGE_NODE];
|
||||
var url = gImageView.data[row][COL_IMAGE_ADDRESS];
|
||||
if (makeURI(url).host == permission.host)
|
||||
if (permission.matchesURI(makeURI(url), true)) {
|
||||
makeBlockImage(url);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
@ -18,7 +18,7 @@ var permissionObserver = {
|
|||
{
|
||||
if (aTopic == "perm-changed") {
|
||||
var permission = aSubject.QueryInterface(Components.interfaces.nsIPermission);
|
||||
if (permission.host == gPermURI.host) {
|
||||
if (permission.matchesURI(gPermURI, true)) {
|
||||
if (gPermissions.indexOf(permission.type) > -1)
|
||||
initRow(permission.type);
|
||||
else if (permission.type.startsWith("plugin"))
|
||||
|
@ -35,7 +35,7 @@ function onLoadPermission()
|
|||
if (SitePermissions.isSupportedURI(uri)) {
|
||||
gPermURI = uri;
|
||||
var hostText = document.getElementById("hostText");
|
||||
hostText.value = gPermURI.host;
|
||||
hostText.value = gPermURI.prePath;
|
||||
|
||||
for (var i of gPermissions)
|
||||
initRow(i);
|
||||
|
|
Загрузка…
Ссылка в новой задаче