Re: release not done right away
Re: release not done right away
- Subject: Re: release not done right away
- From: "Thomas L. Davis" <email@hidden>
- Date: Sat, 24 Apr 2004 19:19:41 -0500
Is there, by chance, a nice, thorough write-up on the Foundation (or
CFRunLoop) event loop? Apple's documentation and the CFRunLoop chapter
in "Core Mac OS X and Unix Programming" leave me with lots of
questions. For example, I added addRunLoopObserver (from "Core ...") to
one of my apps and was surprised to see the loop constantly "entering"
and "exiting". What causes this? Also, I would have thought that
autorelease pools would get deallocated at some point in the run loop,
but I see no documentation about this. I would also think that (at
least certain kinds of) NSNotifications would use the run loop, but
again I see no mention about where in the runloop this occurs (if it
does).
The runloop just seems absolutely central to an event driven GUI app. I
would think that all programmers would need a thorough understanding of
its details. Personally, I think a detailed pseudo code with lots of
comments (including how Cocoa and/or Foundation classes use it) would
be of great help.
Tom
On Apr 21, 2004, at 8:37 AM, j o a r wrote:
Every event you get in your run loop triggers a new event loop, ie. a
cascade of execution of code based on what event you receive. You have
one run loop per thread, but from that run loop is initiated a new
event loop whenever a run loop source has new input.
_______________________________________________
cocoa-dev mailing list | email@hidden
Help/Unsubscribe/Archives:
http://www.lists.apple.com/mailman/listinfo/cocoa-dev
Do not post admin requests to the list. They will be ignored.