I am writing my first extension. It's quite simple, it will match the Outlook behavior where you can (optionally) have a header bar display at the top of messages to which you've replied (i.e. "You replied to this message yesterday; click to view reply message").
So far, I have the UI part worked out pretty well. It's pretty easy to detect messages that have been replied or forwarded by checking the value of the flags associated with that message, and displaying a friendly little explanation and icon in the message window is no problem at all (I modeled it on the existing "junkBar" elements that display a message to the effect of "Mozilla thinks this message is junk mail.")
However, let's say I have message to which the user replied. I'm struggling to look through the code for "Search Messages" (as an example starting point) to figure out how I can implement the functionality I need, which is qutie simply, something to the effect of the following (prototype JavaScript):
getMsgIdsByHeader (name, value) {
// name = "In-Reply-To"
// value = "<[EMAIL PROTECTED]>"
// returns array of messageIds that have a header of name with value
}As you can imagine, I need to implement this functionality so I can not only tell the user "You replied to this message," but offer a link to the reply message. Without knowing the messageId of the message with the In-Reply-To: header set to the value of the current message's messageId, I cannot offer the link functionality.
Can anyone familiar with the various messenger APIs offer some pointers here? I have spent hours pouring through the documentation, but even simple stuff like the list of RDF vocabulary for mailnews is not really documented (originally, I thought maybe I could make some sort of 'assertion' in RDF to get at what I wanted here, but based on my read of nsMsgRDFUtils.h, that's not possible for this scenario). Since this is my first experiment with extensions, I need a little extra help getting started.
Advice would be appreciated. Thanks, -angus _______________________________________________ Mozilla-xpcom mailing list [EMAIL PROTECTED] http://mail.mozilla.org/listinfo/mozilla-xpcom
