How do I pass data and messages between 2 Firefox Add-Ons (the way Google Chrome does it, here)?
+1
A:
All Firefox add-ons share the same global scope when you do an overlay (which essentially every add-on uses). You just need to create some shared object to pass data back and forth on.
sdwilsh
2010-05-19 22:23:54
Thanks so much!
Chetan
2010-05-19 22:27:37
This works but adding to the global namespace is probably not the best strategy. I would say a better approach would be to use JavaScript modules (firefox 3) to create a singleton. See here https://developer.mozilla.org/en/Using_JavaScript_code_modules
fms
2010-05-20 13:38:21