Simple NSWindowController (or window in secondary nib)
Simple NSWindowController (or window in secondary nib)
- Subject: Simple NSWindowController (or window in secondary nib)
- From: Trygve Inda <email@hidden>
- Date: Sun, 07 Feb 2010 04:52:34 +0000
- Thread-topic: Simple NSWindowController (or window in secondary nib)
I have a rather complex NSTableView that is managed by a custom class
"TableController". This manages the array of data that the table will
display
I need to be able to put up a very simple modal window with checkboxes for
each possible column (to set show/hide state) and OK/Cancel buttons.
The checkboxes window is in is own nib, but I'd like to set the
TableController as the file owner so that I can bind the checkboxes to a
keypath in the TableControler (a Mutable Dict with BOOL keys for each
checkbox/column).
Should I just set up a NSWindowController as one of the variables in
TableController and init it programmatically?
[[NSWIndowController alloc] initWithWindowNibName:@"CheckboxWindow"];
Note that TableController is only a subclass of NSObject.
Any drawback to this?
It seems like overkill to create a custom class to manage the checkbox
window when all the checkboxes are controlled by bindings and there is only
an OK/Cancel button.
Any thoughts on a design pattern for this situation?
Thanks,
Trygve
_______________________________________________
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