If in your chrome manifest file you have something like:
overlay chrome://browser/content/browser.xul chrome://path/to/youroverlay.xul
And that overlay has an include to somejsfile.js
and within somejsfile.js you have this:
var myExtension = {
statusBarValue: "Not Initialized Yet",
startup: function startup(){
// Show statusBarValue in Status Bar Panel
},
}
window.addEventListener("load", function() { myExtension.startup(); }, false);
Assuming everything I just said, when the user opens a new window, startup will run for each window and statusBarValue should be "Not Initialized Yet" regardless of what it is in another window.
Because you are overlaying browser.xul, and each window has it's own...each has it's own version of your extension. (Note that this is a new window, not a new tab.)
So yea, you'll probably have to sync them up somehow using a technique similar to what you mentioned.