fixed bug 23089 -- selecting undo after delete cause trash folder to load; r=bienvenu

This commit is contained in:
jefft%netscape.com 2000-02-08 15:48:20 +00:00
parent 2329a4fc3f
commit 61244f6e68

View File

@ -169,6 +169,11 @@ nsLocalMoveCopyMsgTxn::UndoImapDeleteFlag(nsIMsgFolder* folder,
getter_AddRefs(eventQueue));
if (eventQueue)
{
// This is to make sure that we are in the selected state
// when executing the imap url; we don't want to load the
// folder so use lite select to do the trick
rv = imapService->LiteSelectFolder(eventQueue, folder,
urlListener, nsnull);
if (addFlag)
rv =imapService->AddMessageFlags(eventQueue, folder,
urlListener, nsnull,
@ -182,9 +187,8 @@ nsLocalMoveCopyMsgTxn::UndoImapDeleteFlag(nsIMsgFolder* folder,
msgIds.GetBuffer(),
kImapMsgDeletedFlag,
PR_TRUE);
if (NS_SUCCEEDED(rv))
imapService->SelectFolder(eventQueue, folder,
urlListener, nsnull, nsnull);
if (NS_SUCCEEDED(rv) && m_msgWindow)
folder->UpdateFolder(m_msgWindow);
}
}
}