bug 92386, remove-all-sites button is active when it shouldn't be, r=vishy, sr=blake
git-svn-id: svn://10.0.0.236/trunk@100076 18797224-902f-48f8-a5cc-f745e15eee43
This commit is contained in:
parent
1143615f91
commit
d5fa2fddcc
@ -369,18 +369,19 @@ function loadPermissions()
|
||||
contentStr = bundle.GetStringFromName(capability ? "can" : "cannot");
|
||||
AddPermissionToList(cookie_permissions_count, host, type, capability);
|
||||
AddItem("cookiePermList", [host, contentStr], "cookiepermtree_", cookie_permissions_count++);
|
||||
if (cookie_permissions_count == 0) {
|
||||
document.getElementById("removeAllPermissions").setAttribute("disabled","true");
|
||||
}
|
||||
} else if (type == imageType) {
|
||||
contentStr = bundle.GetStringFromName(capability ? "canImages" : "cannotImages");
|
||||
AddPermissionToList(image_permissions_count, host, type, capability);
|
||||
AddItem("imagePermList", [host, contentStr], "imagepermtree_", image_permissions_count++);
|
||||
if (image_permissions_count == 0) {
|
||||
document.getElementById("removeAllImages").setAttribute("disabled","true");
|
||||
}
|
||||
}
|
||||
}
|
||||
if (cookie_permissions_count == 0) {
|
||||
document.getElementById("removeAllPermissions").setAttribute("disabled","true");
|
||||
}
|
||||
if (image_permissions_count == 0) {
|
||||
document.getElementById("removeAllImages").setAttribute("disabled","true");
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
function ViewCookiePermissionSelected()
|
||||
|
||||
@ -302,7 +302,9 @@ function LoadNopreview()
|
||||
currSignon = RemoveHTMLFormatting(currSignon);
|
||||
AddItem("nopreviewlist",[currSignon],"nopreview_",i-1);
|
||||
}
|
||||
nopreviews_count = nopreviewList.length-1;
|
||||
if (nopreviewList) {
|
||||
nopreviews_count = nopreviewList.length-1; // -1 because first item is always blank
|
||||
}
|
||||
if (nopreviews_count == 0) {
|
||||
document.getElementById("removeAllNopreviews").setAttribute("disabled","true");
|
||||
}
|
||||
@ -355,7 +357,9 @@ function LoadNocapture()
|
||||
currSignon = RemoveHTMLFormatting(currSignon);
|
||||
AddItem("nocapturelist",[currSignon],"nocapture_",i-1);
|
||||
}
|
||||
nocaptures_count = nocaptureList.length-1;
|
||||
if (nocaptureList) {
|
||||
nocaptures_count = nocaptureList.length-1; // -1 because first item is always blank
|
||||
}
|
||||
if (nocaptures_count == 0) {
|
||||
document.getElementById("removeAllNocaptures").setAttribute("disabled","true");
|
||||
}
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user