I want to define a variable when Thunderbird starts and for that
variable to be automatically destroyed upon quitting the app.
The best I've succeeded at doing is attaching it in an overlay of
messenger.xul. But messenger.xul is the main window. When the app is
minimized and that main window closes, the variable is destroyed and
when the window is reopened, my variable is reinitialized. I need it to
be persistent while the app is running.
I suppose I could write it to a preference and then add something to
actively remove it on app shutdown. But it would be nicer if I could
just find a scope that exists for the duration of the app running.