I've written a sidebar addon:
- which fetches the current page's URL
- makes a call to a personal server with the URL
- and displays contextual info in the sidebar
Currently, this function is invoked on following events:
- on enabling the addon
- on window load
- on appcontent load
- on TabSelect
However, there are times when a web page takes too long to fire the "load" event. Hence, what I'd prefer is a way to invoke my addon functionality as soon as the first request for the current page is sent.
I'm told that Progress Listener and Observer might be of help. I tried quick and dirty Progress-Listener code, but it didn't work as intended (perhaps, my fault).
Requesting suggestions/links/code-samples. Thanks in advance.