OK - I am getting a lot of education here. I am not a total n00b with Cocoa, and have been studying it and coding it for six years, but I realize that a lot of stuff I memorized how to do, I never understood what I was doing.

On May 15, 2008, at 3:06 PM, [EMAIL PROTECTED] wrote:


Right. I can understand that, that the owner is the shared
application instance. But why do people bind nib objects to File's
Owner?

 Well, in the case of the application object you generally don't do
that. But in the case of an NSDocument-based application or an
NSWindowController subclass, both of which load their own NIBs, the
file's owner is the instance of your NSDocument

Ah - HAH!!!! That's the answer!

These tutorials that say to make a document-based app and don't say why they say that (there are no "documents" in their apps) are doing it ****so they can connect to File's Owner****.

This is why I could not figure out what connecting to File's Owner had to do with being able to bind a controller to a model object. It's because my app is not a document-based app.

Thanks for clarifying that. That indeed was my source of confusion. I see tutorials connecting things to File's Owner and can't figure out why.

I do connect the delegate outlet so I can get notification of applicationWillTerminate: and save my defaults. That is easy to understand.

Thanks

Johnny

_______________________________________________

Cocoa-dev mailing list (Cocoa-dev@lists.apple.com)

Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com

Help/Unsubscribe/Update your Subscription:
http://lists.apple.com/mailman/options/cocoa-dev/archive%40mail-archive.com

This email sent to [EMAIL PROTECTED]

Reply via email to