On 06/07/2010, at 12:02 PM, Kyle Sluder wrote:

> Have you tried making a canonical sortDescriptors property on an
> appropriate controller (probably a window controller or view
> controller) and binding both the table view and icon view's
> sortDescriptors to this property? This seems more appropriate than
> synchronizing state between views.


I was hoping to avoid it because if I do that I have to duplicate the work that 
NSTableView does to maintain its list of sort descriptors. Since NSTableView 
already manages this list, it's easy to use.

However now I'm having to duplicate this work anyway since NSTableView isn't 
working in the way I expected, so maybe moving the sort descriptors to the 
controller altogether might work out the better approach. Bit of a redesign at 
this stage though.

I'd still like to know how a programmatic change to sort descriptors in a table 
view ought to be accomplished. It seems that the "highlighted" column really 
has logically nothing to do with the table's sort descriptors, even though when 
you interact with a table that's exactly what is used to indicate the sorted 
column. Weird.

--Graham


_______________________________________________

Cocoa-dev mailing list (Cocoa-dev@lists.apple.com)

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:
http://lists.apple.com/mailman/options/cocoa-dev/archive%40mail-archive.com

This email sent to arch...@mail-archive.com

Reply via email to