Re: Remove NSTableView Default Selection
Re: Remove NSTableView Default Selection
- Subject: Re: Remove NSTableView Default Selection
- From: Corbin Dunn <email@hidden>
- Date: Fri, 25 Sep 2009 08:14:25 -0700
On Sep 24, 2009, at 8:12 PM, Jens Alfke wrote:
On Sep 24, 2009, at 5:07 PM, John McIntosh wrote:
I assumed that I could send the same deselectAll message in either an
awakeFromNib function or applicationDidFinishLaunching. However,
neither of these clears the selection.
Make sure you've checked the table's "Empty" checkbox (allow empty
selection) in the nib.
Also, if there's a controller bound to the table, uncheck its "Avoid
empty selection" checkbox.
Some additional information to what Jens said:
"action" based methods, like the user selecting a row, -deselectAll:
and -selectAll:, respect the "allows empty selection" setting and will
keep an item selected if turned off and if possible.
Programmer methods will override that behavior. So, if you call [table
selectRowIndexes:[NSIndexSet indexSet] byExtendingSelection:NO], you
should still be able to get an empty selection.
corbin
_______________________________________________
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