Load View from .nib in Bundle.
Load View from .nib in Bundle.
- Subject: Load View from .nib in Bundle.
- From: Totte <email@hidden>
- Date: Tue, 27 May 2003 09:50:09 +0200
Hello Cocoa gurus.
I'm playing around with the Bundle/Plugin architecture of Cocoa, and
got the loading to work properly (can call methods in the bundle, and
NSLog() says I'm there OK, but, I need to load a View from a Nib-file,
and install that into a NSBox passed from the calling main application,
and my primitive Cocoa experience makes me trip on the "simple" task of
loading a nibfile from within a Bundle (in the bundle principal class
itself). See the method below. Maybe I'm totally off here.
// Install inside
- (void)installViewIntoBox:(NSBox *)aBox
{
// Locals
NSView* myLoadedView;
// Magic code to load the view.
storyLineView = [someMagicCode here];
// Install into passed box
[aBox setContentView: myLoadedView];
}
// Totte
_______________________________________________
cocoa-dev mailing list | email@hidden
Help/Unsubscribe/Archives:
http://www.lists.apple.com/mailman/listinfo/cocoa-dev
Do not post admin requests to the list. They will be ignored.