C�dric wrote:
On Thu, 18 Sep 2003 12:00:41 +0200, Piercarlo Slavazza wrote:


C�dric wrote:

On Tue, 16 Sep 2003 01:20:26 -0700, piercarlo wrote:



[...]
My question is: how can I detect when a tab (with some page yet
loaded) is taken to foreground (so I can change accordingly the
content of my sidebar)? Is there some proper event to be used with
addObserver()?
More in general, where can I find a list with all the events?

Thanks a lot!
bye
piercarlo


I'm not sure but you have to add a progressListener to the tab browser
object

Ok. Do you have any idea of the way I can get a reference to that object? Always through XPCOM or whatever else?


Thanks!
piercarlo


in javascript you have to do that :
yourBrowser.addProgressListener(myProgressListener,
                                  
Components.interfaces.nsIWebProgress.NOTIFY_LOCATION);

[...]
and through XPCOM you should have to do something similar but I don't know
exactly what. Sorry, I hope my previous example in javascript help you.

Yes, Javascript its fine for me (actually I am writing a Mozilla addon for the sidebar). But (please be patient!), what I am supposed to replace with the string "yourBrowser" in "yourBrowser.addProgressListener"? Let's pretend that I'm using - to be precise - Mozilla 1.4 (and possibly Netscape 7.1, which, I think, behaves the same as Mozilla1.4).


Thanks again!
piercarlo




Reply via email to