Re: [NEWBIE QUESTION] What message is sent when window contents finish loading?
Re: [NEWBIE QUESTION] What message is sent when window contents finish loading?
- Subject: Re: [NEWBIE QUESTION] What message is sent when window contents finish loading?
- From: mw <email@hidden>
- Date: Sun, 29 Sep 2002 12:14:35 -0400
>
> Well, I'm not sure if it is. The main window has all of its functions
>
> in the
>
> default MyDocument class which PB sticks in the project by default
>
> when you
>
> make a new document-based cocoa app. MyDocument is a subclass of
>
> NSDocument.
>
> Should I, perhaps, create another class that is a subclass of
>
> NSWindowController, and then just make an instance of MyDocument in
>
> it? If I
>
> did that, would I have to change the class of File's Owner in
>
> MyDocument.nib
>
> (which contains the main window and such)?
>
>
Ah, yes... I keep forgetting that the template is set up that way. I
>
have followed the model set forth in Vermont Recipes (an excellent
>
series of tutorials by Bill Cheeseman, available at www.stepwise.com),
>
in which the "controller" tasks are divided between the NSDocument
>
subclass and the NSWindowController subclass. If you do it this way,
>
you do indeed change the custom class of File's Owner. A lot of things
>
(including the ability to use the -windowDidLoad method) become simpler
>
when you do it this way. Check out the Vermont Recipes tutorials!
>
Okay, I went to that website and followed the tutorial. It helped a little.
There are still some confusing points for me to pick up on. The overall
structure of the messaging in this form is still slightly confusing because
I had been storing all of the functions in the NSDocument subclass, and now
everything had to be moved to the new NSWindowController subclass... But
hopefully I'll get it eventually ;-).
Thanks for your help! Stepwise.com has a lot of other resources on it that I
had been searching for, but had never found.
mw
_______________________________________________
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.