> Hello again.
> I seem to be having a problem understanding the sequence of events
> that NSDoent programs go through for initialization. Here is my
> setup, followed by my question.
> I have an NSDoent program that opens up a window holding a subclass
> of NSOpenGLView. I need to pass a parameter to this NSOpenGLView
> subclass *before* it can start calling drawRect. Through NSLog
> outputs, I have determined the function-call sequence to be:
> Begin: MyDoent->init
> End: MyDoent->init
> Begin: MyOpenGLVIew->initWithCoder
> End: MyOpenGLVIew->initWithCoder
> Begin: MyOpenGLVIew->awakeFromNib
> End: MyOpenGLVIew->awakeFromNib
> Begin: MyOpenGLVIew->drawRect
> End: MyOpenGLVIew->drawRect
> Begin: MyDoent->windowControllerDibLoadNib
> End: MyDoent->windowControllerDibLoadNib
> Ideally, I would like to be able to call my own function between the
> MyOpenGLVIew->awakeFromNib and drawRect, but I can't seem to find a
> place within MyDoent to do that. I tried passing the parameter
> during MyDoent->init, but because MyOpenGLView->initWithCoder has
> not been called yet, it doesn't seem to work (although I receive no
> errors; not even a SegV or BusError...).
> How does one pass in parameters for an OpenGLView before the first
> call to drawRect?