filled in MsgEmptyTrash() function

This commit is contained in:
jefft%netscape.com 1999-08-06 18:22:05 +00:00
Родитель 60c85eb9b2
Коммит 37b4c3a63e
1 изменённых файлов: 34 добавлений и 11 удалений

Просмотреть файл

@ -265,22 +265,45 @@ function MsgLoadFirstDraft()
}
function MsgUpdateMsgCount() {}
function MsgRenameFolder() {}
function MsgEmptyTrash() {}
function MsgEmptyTrash()
{
var tree = GetFolderTree();
if (tree)
{
var folderList = tree.getElementsByAttribute("selected", "true");
if (folderList)
{
var folder;
folder = folderList[0];
if (folder)
messenger.EmptyTrash(tree.database, folder);
}
}
}
function MsgRenameFolder() {}
function MsgCompactFolder()
{
//get the selected elements
var tree = GetFolderTree();
var folderList = tree.getElementsByAttribute("selected", "true");
var i;
var folder;
for(i = 0; i < folderList.length; i++)
{
folder = folderList[i];
folderuri = folder.getAttribute('id');
dump(folderuri);
dump("folder = " + folder.nodeName + "\n");
messenger.CompactFolder(tree.database, folder);
if (tree)
{
var folderList = tree.getElementsByAttribute("selected", "true");
if (folderList)
{
var i;
var folder;
for(i = 0; i < folderList.length; i++)
{
folder = folderList[i];
if (folder)
{
folderuri = folder.getAttribute('id');
dump(folderuri);
dump("folder = " + folder.nodeName + "\n");
messenger.CompactFolder(tree.database, folder);
}
}
}
}
}