зеркало из https://github.com/mozilla/gecko-dev.git
fix for #148078. context menu problems in stand alone msg window.
use GetLoadedMsgFolder() instead of GetSelectedFolderResource(). regression caused by #138018. r/sr=bienvenu.
This commit is contained in:
Родитель
ed8e670065
Коммит
3e8138e699
|
@ -157,14 +157,10 @@ function SetupForwardAsAttachmentMenuItem(menuID, numSelected, forceHide)
|
|||
function SetupMoveMenuItem(menuID, numSelected, isNewsgroup, forceHide)
|
||||
{
|
||||
ShowMenuItem(menuID, !isNewsgroup && !forceHide);
|
||||
var folderResource = GetSelectedFolderResource();
|
||||
var enableMenuItem = numSelected > 0;
|
||||
|
||||
var msgFolder = GetLoadedMsgFolder();
|
||||
// disable move if we can't delete message(s) from this folder
|
||||
if (folderResource)
|
||||
{
|
||||
var msgFolder = folderResource.QueryInterface(Components.interfaces.nsIMsgFolder);
|
||||
enableMenuItem = enableMenuItem && msgFolder && msgFolder.canDeleteMessages;
|
||||
}
|
||||
var enableMenuItem = (numSelected > 0) && msgFolder && msgFolder.canDeleteMessages;
|
||||
EnableMenuItem(menuID, enableMenuItem);
|
||||
}
|
||||
|
||||
|
|
Загрузка…
Ссылка в новой задаче