This commit is contained in:
putterman%netscape.com 1999-05-07 00:34:22 +00:00
Родитель 7354a7f1d7
Коммит 91c5a4bef6
2 изменённых файлов: 27 добавлений и 0 удалений

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

@ -539,6 +539,32 @@ NS_IMETHODIMP nsImapMailFolder::GetThreadForMessage(nsIMessage *message,
return rv;
}
//This needs to be moved up into common base class.
NS_IMETHODIMP
nsImapMailFolder::HasMessage(nsIMessage *message, PRBool *hasMessage)
{
if(!hasMessage)
return NS_ERROR_NULL_POINTER;
nsresult rv = GetDatabase();
if(NS_SUCCEEDED(rv))
{
nsCOMPtr<nsIMsgDBHdr> msgDBHdr, msgDBHdrForKey;
nsCOMPtr<nsIDBMessage> dbMessage(do_QueryInterface(message, &rv));
nsMsgKey key;
if(NS_SUCCEEDED(rv))
rv = dbMessage->GetMsgDBHdr(getter_AddRefs(msgDBHdr));
if(NS_SUCCEEDED(rv))
rv = msgDBHdr->GetMessageKey(&key);
if(NS_SUCCEEDED(rv))
rv = m_mailDatabase->ContainsKey(key, hasMessage);
}
return rv;
}
NS_IMETHODIMP nsImapMailFolder::CreateSubfolder(const char *folderName)
{
nsresult rv = NS_OK;

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

@ -66,6 +66,7 @@ public:
NS_IMETHOD GetMessages(nsIEnumerator* *result);
NS_IMETHOD GetThreads(nsIEnumerator** threadEnumerator);
NS_IMETHOD GetThreadForMessage(nsIMessage *message, nsIMsgThread **thread);
NS_IMETHOD HasMessage(nsIMessage *message, PRBool *hasMessage);
NS_IMETHOD CreateSubfolder(const char *folderName);