Re: Dynamically loading NIB files into sheets
Re: Dynamically loading NIB files into sheets
- Subject: Re: Dynamically loading NIB files into sheets
- From: j o a r <email@hidden>
- Date: Tue, 16 Apr 2002 19:51:32 +0200
On Tuesday, April 16, 2002, at 08:12 , Sebastian Celis wrote:
[NSApp beginSheet:[theSheetController window]
Can you do something like this somewhere and see what is returned, does
it match what you expected to find?
NSLog(@"SheetController window: %@", [theSheetController window]);
NSLog(@"SheetController window title: %@", [[theSheetController window]
title]);
If you implement "windowDidLoad" in your sheet controller (that still is
a subclass of NSWindowController I hope...) is it ever called?
aSheetController = [[SheetControllerA alloc] init];
[theSheetControllers setObject:aSheetController
forKey:identifier];
return aSheetController;
Not related to your other problem, but you might consider doing
something like this instead:
aSheetController = [[SheetControllerA alloc] init];
[theSheetControllers setObject:aSheetController forKey:identifier];
[aSheetController release]
return aSheetController;
In this way the sheet controller is retained only by the container
object, thus removing it from that object, or releasing it, will also
release all contained sheet controllers. It's probably easier that way
in the long run.
j o a r
_______________________________________________
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.