• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
How to sort smoothly when NSTableColumn's Sort Key is empty
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

How to sort smoothly when NSTableColumn's Sort Key is empty


  • Subject: How to sort smoothly when NSTableColumn's Sort Key is empty
  • From: an0 <email@hidden>
  • Date: Tue, 3 Jun 2008 23:52:26 +0800

I know how to sort items in NSTableView when each NSTableColumn
corresponds to a property of the item object.
But what if there is only one NSTableColumn and it is just mapped to
the item object itself instead of a property of it?
I set the Selector to "compare:" and leave the Sort Key to empty for
the NSTableColumn in Interface Builder. It seems items can be sorted
once in such a case but the order can not be reverted by clicking the
column header again.
And the NSTableView's sortDescriptors are found cumulated instead of
changed by NSLog in dataSource's tableView:sortDescriptorsDidChange:
method.
What is the right configuration for such a case then?
_______________________________________________

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

  • Follow-Ups:
    • Re: How to sort smoothly when NSTableColumn's Sort Key is empty
      • From: "Hamish Allan" <email@hidden>
  • Prev by Date: Re: trying to glue a cocoa ui to a pthread application / subclassing nsview
  • Next by Date: Re: File still in use after closing document window
  • Previous by thread: Re: CoreData file format stability
  • Next by thread: Re: How to sort smoothly when NSTableColumn's Sort Key is empty
  • Index(es):
    • Date
    • Thread