Re: Unclear on -makeWindowControllers in doc-based app
Re: Unclear on -makeWindowControllers in doc-based app
- Subject: Re: Unclear on -makeWindowControllers in doc-based app
- From: John Pannell <email@hidden>
- Date: Sun, 11 Dec 2005 12:19:02 -0700
Hi Andrew-
I was just reading up on this the other day... I believe the
following document is stating that the document-based architecture
"does the right thing" as long as you do the right thing
(addWindowController:)
file:///Developer/ADC Reference Library/documentation/Cocoa/
Conceptual/Documents/Concepts/WindowClosingBehav.html#//apple_ref/doc/
uid/20000027
Relevant passage:
When the last window of a document is closed, the document is also
closed. The window, window controller, and document are all released.
When a primary window of a document is closed, the document is also
closed, as are any secondary document windows. The document’s
windows, the document’s window controllers, and the document itself
are released.
When a secondary window of a document is closed, only that window is
closed. The window controller is removed from the document’s list of
window controllers. The secondary window and its window controller
are released.
It sounds like the architecture takes care of itself. I'm no expert,
however; others with better knowledge feel free to correct me!
HTH-
John
John Pannell
Positive Spin Media
http://www.positivespinmedia.com
On Dec 11, 2005, at 12:05 PM, Andrew Merenbach wrote:
If one has a document-based application and has overridden -
makeWindowControllers, so as to put the window controller
functionality in one class and the document functionality in
another, how does one release the created window controller?
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Cocoa-dev mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden