Thanks guys, Just as a footnote to this - I've implemented nsITimer as described in the example that Christian sent me and tested it on Netscape v7.2 and Mozilla v1.7.6 - as you'd probably expect it worked fine on both - testing on FireFox later - I'm sure it'll work there as well :)
Thanks, Damien > -----Original Message----- > From: [EMAIL PROTECTED] > [mailto:[EMAIL PROTECTED] On Behalf Of > Christian Biesinger > Sent: 21 April 2005 19:48 > To: [email protected] > Subject: Re: Timer that calls a function at regular intervals. > > > Damien O'Brien wrote: > > A) Is nsITimer the right thing to use or is there something better? > > Yeah, it's the right one, like bsmedberg said. > > > B) Can anyone point me at an example of how to use nsITimer? > http://lxr.mozilla.org/seamonkey/source/extensions/inspector/base/src/in SearchLoop.cpp#61 is an example from the DOM inspector code. All you have to do is init the timer, and it will fire as specified. > C) I don't think nsITimer comes as part of the Gecko SDK - is that > correct? Yes, the SDK only contains frozen interfaces. _______________________________________________ Mozilla-xpcom mailing list [email protected] http://mail.mozilla.org/listinfo/mozilla-xpcom
