Re: Using Notifiers for a non-CFRunLooped app ??
Re: Using Notifiers for a non-CFRunLooped app ??
- Subject: Re: Using Notifiers for a non-CFRunLooped app ??
- From: Jérome Foucher <email@hidden>
- Date: Thu, 12 Dec 2002 19:17:49 +0100
On jeudi, dic 12, 2002, at 15:17 Europe/Paris, Quinn wrote:
At 14:20 +0100 12/12/02, Jirome Foucher wrote:
One thing to notice however, is that the registration of these
callbacks HAS to be done in the main thread... at least for me. If I
register them in another thread, no error occurs, but the callbacks
are never called.
Each thread has its own runloop. When you call CFRunLoopGetCurrent,
you get the runloop for that particular thread. Unless you code it
otherwise, only your main thread ever runs its runloop. A non-main
threads can run its runloop by calling CFRunLoopRun; if you don't do
that, callbacks attached to that thread's runloop never run.
Oh, ok I see now.
Thanks for these usefull explanations.
Jerome
_______________________________________________
macnetworkprog mailing list | email@hidden
Help/Unsubscribe/Archives:
http://www.lists.apple.com/mailman/listinfo/macnetworkprog
Do not post admin requests to the list. They will be ignored.