Re: Problem with multiple instances of a nib
Re: Problem with multiple instances of a nib
- Subject: Re: Problem with multiple instances of a nib
- From: Rob Keniger <email@hidden>
- Date: Mon, 23 Nov 2009 08:58:24 +1000
On 23/11/2009, at 8:49 AM, PCWiz wrote:
> Good to know that I'm not the only one experiencing this. The easiest solution I guess is to keep an array of the controller objects, which I will try. Is this how you mean:
>
> NSMutableArray *controllerObjects = [[NSMutableArray alloc] init];
> ImagePanelController *newController = [[[ImagePanelController alloc] init] autorelease];
> [controllerObjects addObject:newController];
>
> With this method, when the panel is closed would the controller be removed from the array (I'm guessing not, and if so, how would I make it do that?)
Register the object that manages the array as a delegate of the window, implement -windowWillClose: and remove the appropriate window controller from the array?
--
Rob Keniger
_______________________________________________
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