Re: NSTableView default sort column?
Re: NSTableView default sort column?
- Subject: Re: NSTableView default sort column?
- From: mmalc Crawford <email@hidden>
- Date: Fri, 22 Jun 2007 21:09:56 -0700
On Jun 22, 2007, at 8:16 PM, Joe Goh wrote:
selector:@selector(caseInsensitiveCompare:)]];
Since the strings here are to be presented to the user, the selector
should almost certainly be
@selector(localizedCaseInsensitiveCompare:)
(The documentation is being updated to make this point pervasively...)
[someTableView setSortDescriptors:[NSArray
arrayWithObject:sortDescriptor]];
Since the OP mentioned he's using an array controller, it may be more
appropriate to set the sort descriptors on that instead:
[arrayController setSortDescriptors:[NSArray
arrayWithObject:sortDescriptor]];
or even to bind the array controller's sortDescriptors to another
controller object (if you want to keep track of them).
mmalc
_______________________________________________
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