Re: [SOLVED] Two NSTableViews acting as one
Re: [SOLVED] Two NSTableViews acting as one
- Subject: Re: [SOLVED] Two NSTableViews acting as one
- From: Jason Bell <email@hidden>
- Date: Wed, 2 Nov 2005 20:38:25 -0500
Karl's original suggestion was a good one. I unfortunately did not
have the bindings set correctly at first. However, my mistake did
allow me to learn something about value transformers. Anyway, here
is my final solution:
1) Each table's selectionIndexes bound to the proper arrayContoller's
selectionIndexes.
2) "Avoids empty selection" checked for the static table but not for
the dynamic one.
3) Code in the delegate of the dynamic table to avoid an empty
selection when clicking in the table's "empty space". Using "avoids
empty selection" causes the first new row to be selected upon
insertion (don't want).
4) Code to handle the case where a delete would cause the dynamic
table to become empty and nothing to be selected (answer: select the
last row in static table).
The end result appears to the user as a single tableView that does
not allow an empty selection.
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Cocoa-dev mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden