Adapt to Changes in Thunderbird 103-115
This document tries to cover the internal changes that may be needed to make Experiment add-ons compatible with Thunderbird Supernova. If you find changes which are not yet listed on this page, you can ask for help and advice in one of our communication channels.
mailMessageTabin Thunderbird's main messenger window is now loaded into its own browser element, instead of sharing and updating a single browser.
about:3pane) can now be accessed as follows:
window.gTabmail.tabInfo.find( t => t.mode.name == "mail3PaneTab" ).chromeBrowser.contentWindow
Options #1 & #2 will only work if the current active tab is a
mail3PaneTab. Option #3 assumes the first tab is always a
about:message) can be accessed similarly:
Option #1 will only work if the current tab is a
mailMessageTab. Option #2 will return the
mailMessageWindow, if the current tab is a
mailMessageTab(it will return the
mail3PaneWindow, if the current tab is a
mail3PaneTab). Option #3 will return the nested message browser of a
mail3PaneWindowas defined in the previous section. Option #4 will return the message browser of a message window.
Some of the global objects defined in Thunderbird's main messenger window have been moved into the
about:3pane) and/or the
about:message). Some objects have been removed.
gDBView: Available in
gFolderDisplay: Removed. Find displayed folder via
gMessageDisplay: Removed. Find displayed message via
Useful functions, methods and objects which have been moved from elsewhere:
It is recommended to leverage WebExtension APIs as much a possible. Instead of adjusting to core changes, the following WebExtension APIs can be helpful:
There may already be a shared Experiment, which could help with add-on updates (or which could give helpful hints):
The mail toolbar has been replaced by the unified toolbar. Adding your own buttons will become difficult, because the unified toolbar tends to remove unknown objects. Instead, use the browserAction API to add buttons.
mail3PaneTab) no longer use the deprecated XUL
treeelements, but have been replaced by HTML
Known attributes which have to be replaced:
const Services = globalThis.Services;
For a backward compatible solution, use
const Services = globalThis.Services || ChromeUtils.import("resource://gre/modules/Services.jsm").Services;
Removed in Thunderbird 115. Can be replaced as follows:
In Thunderbird 106, this has been changed from an enumerator to a simple array.
Removed in Thunderbird 106.
Renamed in Thunderbird 108 to
Content processes, such as the extension process executing "child" experiment code, are subject to additional restrictions compared to Thunderbird 102. Known limitations include:
- Raw TCP socket operations never complete, even if timeouts are set up. It is likely that other networking primitives are affected in a similar way.
In consequence, you might need to move some functionality from "child" experiment code to the "parent" context. One way to achieve this is to implement the necessary functionality as a regular asynchronous API method in the "parent" experiment (without extending the API schema), then using
await context.childManager.callParentAsyncFunction("your_api_name.some_function", [arguments, passed, to, some_function])to call it from the child experiment. Note that function arguments passed in between processes are subject to the structured clone algorithm.