Adding self as Nib owner
Adding self as Nib owner
- Subject: Adding self as Nib owner
- From: Ian was here <email@hidden>
- Date: Thu, 10 Jan 2008 12:05:39 -0800 (PST)
I recently noticed that when I add an instance of my
object as the owner of a Nib, that it's retain count
jumps to two.
- (id)init
{
if ( self = [super init] )
{
[NSBundle loadNibNamed:@"MyNib" owner:self];
}
return self;
}
I've Googled this and learned that when my instance
finally is deallocated, that the Nib file it owns is
not. Apparently, the top level objects on the Nib file
(NSWindow, NSMenu, etc...) need to be manually released?!
____________________________________________________________________________________
Be a better friend, newshound, and
know-it-all with Yahoo! Mobile. Try it now. http://mobile.yahoo.com/;_ylt=Ahu06i62sR8HDtDypao8Wcj9tAcJ
_______________________________________________
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