MozillaZine

Conditional xul overlay

Talk about add-ons and extension development.
MartinWH
 
Posts: 5
Joined: April 18th, 2013, 1:22 am

Post Posted February 3rd, 2019, 11:58 am

Hi everyone!

I am absolutely new to extension development for Thunderbird. I wanted to ask how I can get a conditional xul overlay. I want a button in the msg Header only to be displayed when a mail comes from a specific sender.

Can you give me some advice?

Best regards

morat
 
Posts: 3105
Joined: February 3rd, 2009, 6:29 pm

Post Posted February 3rd, 2019, 10:23 pm

Here is an example extension that adds a button to the message header view toolbar.

The button changes its style dependent on a property of the selected message.

Filter Button
http://addons.thunderbird.net/thunderbird/addon/407832

Code: Select all
var msg = gFolderDisplay.selectedMessage;
var sender = msg.mime2DecodedAuthor;

nsIMsgDBHdr
http://developer.mozilla.org/docs/Mozilla/Tech/XPCOM/Reference/Interface/nsIMsgDBHdr

MartinWH
 
Posts: 5
Joined: April 18th, 2013, 1:22 am

Post Posted February 4th, 2019, 3:20 am

Thank you very much. I will take a look into that and reply again to this thread later.

Best regards

Return to Extension Development


Who is online

Users browsing this forum: No registered users and 2 guests