• 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: Cocoa Open GL help
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Cocoa Open GL help


  • Subject: Re: Cocoa Open GL help
  • From: Vince DeMarco <email@hidden>
  • Date: Tue, 11 Sep 2001 10:57:01 -0700

On Tuesday, September 11, 2001, at 06:11 am, Raphael Sebbe wrote:

objects in nib files are inited with :

-initWithFrame: (NSView subclasses)
-init (other objects)

So, you should override initWithFrame, I believe.

-awakeFromNib, on the other hand is invoked after all nib objects have been brought to life.


This is completely wrong.

here is a note we added in the IB FAQ to explain this.

 Why isn't my initWithFrame: method called?

initWithFrame: is only called when you have added a Custom View object to your window. The initWithFrame: message is sent to the class you specified in the Attributes Info Panel. Other widgets will not recieve initWithFrame:
messages. In this case you should just implement a -(void)awakeFromNib method to handle any further setup at runtime

vince


  • Follow-Ups:
    • Re: Cocoa Open GL help
      • From: Raphael Sebbe <email@hidden>
References: 
 >Re: Cocoa Open GL help (From: Raphael Sebbe <email@hidden>)

  • Prev by Date: Re: Creating NSBitmapImageRep from NSImage
  • Next by Date: Re: Creating NSBitmapImageRep from NSImage
  • Previous by thread: Re: Cocoa Open GL help
  • Next by thread: Re: Cocoa Open GL help
  • Index(es):
    • Date
    • Thread