• 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: NSDocumentController subclass not instantiated first?
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: NSDocumentController subclass not instantiated first?


  • Subject: Re: NSDocumentController subclass not instantiated first?
  • From: Kyle Sluder <email@hidden>
  • Date: Sun, 7 Mar 2010 17:10:14 -0800

On Sun, Mar 7, 2010 at 4:09 PM, Keith Blount <email@hidden> wrote:
> Running some test NSLogs, it certainly seems that NSDocumentController’s -initialize method is called before that of my application delegate - although I’m not entirely sure that is telling or not. I’ve been through my code looking for calls to NSDocumentController, trying to find any calls that could conceivably occur before MainMenu.nib gets initiated, but so far I’m stumped.

It's important to make a distinction between +initialize (the class
method which is sent by the runtime the first time a class is sent a
message) and -init (the instance method used to initialize an object).

As Quincy says, set a breakpoint on -sharedDocumentController. If that
doesn't work, you could load your app up in Instruments and use the
Object Graph template to find out where the first NSDocumentController
instance is allocated.

--Kyle Sluder
_______________________________________________

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: NSDocumentController subclass not instantiated first? [SOLVED]
      • From: Keith Blount <email@hidden>
References: 
 >NSDocumentController subclass not instantiated first? (From: Keith Blount <email@hidden>)

  • Prev by Date: Re: NSDocumentController subclass not instantiated first?
  • Next by Date: Bypassing action method in NSSegmentedControl
  • Previous by thread: Re: NSDocumentController subclass not instantiated first?
  • Next by thread: Re: NSDocumentController subclass not instantiated first? [SOLVED]
  • Index(es):
    • Date
    • Thread