Re: Sort ordering and custom cells
Re: Sort ordering and custom cells
- Subject: Re: Sort ordering and custom cells
- From: Gideon King <email@hidden>
- Date: Wed, 14 Jul 2010 08:38:07 +1000
Thanks for trying to help, but I'm not sure the meaning of your answer, or what other information I could provide about the situation. Could you please clarify?
Regards
Gideon
On 14/07/2010, at 5:29 AM, Keary Suska wrote:
> On Jul 13, 2010, at 10:38 AM, Gideon King wrote:
>
>> Hi,
>>
>> I have an NSTableView bound to an NSArrayController, which gets its data from an NSMutableArray of objects.
>>
>> One column of my table is set up as a button cell where I use tableView:dataCellForTableColumn:row: to return a different button cell (or sometimes nil) depending on the data for that row.
>>
>> When I sort the table, the buttons are not sorted - they just stay in the row they were in. Ditto for when I add new rows.
>>
>> What's a good way to fix this?
>
> If I were to hazard a guess--which is what I have to do since you have given us very little to go on--I would say that you need to be using NSArrayController's -arrangedObjects to determine the button value.
>
> Keary Suska
> Esoteritech, Inc.
> "Demystifying technology for your home or business"
>
_______________________________________________
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