Re: Ownership of nib instances
Re: Ownership of nib instances
- Subject: Re: Ownership of nib instances
- From: Joe Chan <email@hidden>
- Date: Wed, 17 Oct 2001 23:08:14 -0400
I think I mostly understand, except one point: if the file's
owner always release the top level objects, how is window
controllers special: they release all the top level objects just
like other file owner's do, right?
On Wednesday, October 17, 2001, at 07:52 PM, cocoa-dev-
email@hidden wrote:
Here are <echoing voice> THE RULES:
The File's Owner owns any top level items in the nib. Basically
everything in the document window except First Responder* is a
Top Level
Object. It is the responsibility of the File's Owner to release top
level objects. There are some exceptions. For convenience**, windows
will commit suicide for you if you check the Release on Close
box. Also,
as mentioned below, if the File's Owner is a window controller, it will
help you out by releasing any top level objects for you.
Scott.
*The First Responder isn't a real object. It's an abstract
representation of the responder chain and therefore cannot be
released...although you can try (it's nil).
**For whose convenience I don't know...certainly not mine, since I'm
left explaining it all of the time, but I'm happy to do it.
-----------
Joe Chan
email@hidden
http://www.firstian.com