Re: viewDidLoad not called
Re: viewDidLoad not called
- Subject: Re: viewDidLoad not called
- From: Cody Garvin <email@hidden>
- Date: Tue, 15 Jul 2014 22:22:41 -0700
NSViewController does not have a viewDidLoad or viewDidAppear or viewWillAppear.
If you need to layout subviews or do additional setup you can use loadView or awakFromNib.
- Cody
> On Jul 15, 2014, at 9:52 PM, Marco S Hyman <email@hidden> wrote:
>
> Hello all,
>
> I'm sure I've forgotten to do something simple... perhaps one of you
> can apply a cluebat.
>
> I'm playing with a swift project on OS X (but that probably has nothing
> to do with anything). I've a single window with a view and in that view
> I have a table view among other things. All are in MainMenu.xib.
> Instead of subclassing NSTableView I thought I'd try something different
> and created a TableViewController subclass of NSViewController that is
> also the table view delegate and data source. So far so good.
>
> I added an object to the nib representing my TableViewClass. Outlets
> seem to be set up correctly. The delegate/data source methods are
> being called. What is not being called is viewDidLoad, or
> viewWillAppear, or viewDidAppear as the app is launched.
>
> Shouldn't those functions be called. What did I forget to do?
>
> Marc
> _______________________________________________
> Do not post admin requests to the list. They will be ignored.
> Xcode-users mailing list (email@hidden)
> Help/Unsubscribe/Update your Subscription:
>
> This email sent to email@hidden
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Xcode-users mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden