• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
Re: app delegate +initialize
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: app delegate +initialize


  • Subject: Re: app delegate +initialize
  • From: Rob Keniger <email@hidden>
  • Date: Thu, 8 Oct 2009 15:00:08 +1000

On 08/10/2009, at 1:39 PM, John Baldwin wrote:

> Inside the xib is a window which is set to visible at launch. The error happens in the window controller for this window, which is expecting the user defaults to be initialized by the AppController instance.
>
> So I'm expecting the AppController instance to be loaded and the +initialize method to be called before my window controller is loaded and its outlets start getting referenced.


Both the responses to this have been spot on, but I'd just add that what you can do is create your window in a separate xib, and then instantiate your window controller programmatically from your AppController at a point where you know the user defaults have been loaded. That way you don't need to worry about the order of loading objects from the xib as you control it explicitly.

--
Rob Keniger



_______________________________________________

Cocoa-dev mailing list (email@hidden)

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:

This email sent to email@hidden

  • Follow-Ups:
    • Re: app delegate +initialize
      • From: John Baldwin <email@hidden>
References: 
 >Re: app delegate +initialize (From: John Baldwin <email@hidden>)
 >Re: app delegate +initialize (From: John Baldwin <email@hidden>)
 >Re: app delegate +initialize (From: Jens Alfke <email@hidden>)
 >Re: app delegate +initialize (From: John Baldwin <email@hidden>)

  • Prev by Date: Re: I think there's a problem in the documentation for NSComboBox
  • Next by Date: Re: Base64 encoding and deprecated stringWithCString: length:
  • Previous by thread: Re: app delegate +initialize
  • Next by thread: Re: app delegate +initialize
  • Index(es):
    • Date
    • Thread