Re: Instantiating Objects in Nib Files
Re: Instantiating Objects in Nib Files
- Subject: Re: Instantiating Objects in Nib Files
- From: mmalcolm crawford <email@hidden>
- Date: Sun, 16 Nov 2003 00:13:36 -0800
On Nov 15, 2003, at 11:52 PM, Dietrich Epp wrote:
Is there any particular reason, then, for trying to instantiate
[NSDocumentController] in the nib? Just send messages to it
programatically:
[NSDocumentController sharedDocumentController]
(*As far as I can tell*, all the action methods it implements should
be handled automatically.)
I wanted to put it in the nib so I could make nib connections to it.
Then, when I subclassed it, I wouldn't have to change that part. It's
not important.
It's still not clear why you need connections...
And no, the action methods aren't automatic... something has to
connect the Save menu command to something. For now I'll just connect
it to the first responder.
The Save menu *should* be connected to First Responder -- whichever is
the document object for the Main window is the object that should
receive the saveDocument: message...
Are you sure you're not confusing NSDocumentController and NSDocument?
mmalc
_______________________________________________
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.