Re: NSTableView ignores changes to cell's objectValue outside mouse tracking methods?
Re: NSTableView ignores changes to cell's objectValue outside mouse tracking methods?
- Subject: Re: NSTableView ignores changes to cell's objectValue outside mouse tracking methods?
- From: Corbin Dunn <email@hidden>
- Date: Mon, 29 Mar 2010 14:40:08 -0700
On Mar 29, 2010, at 2:05 PM, Sean McBride wrote:
> On Fri, 26 Feb 2010 13:20:08 -0800, Corbin Dunn said:
>
>> Take a look at the "AnimatedTableView" demo app. I added a custom color
>> well cell type of thing, and demonstrate how to update values outside
>> the normal click+tracking way of doing things. Last years WWDC talk
>> covered this too (I think you can buy it on iTunes).
>
> Corbin,
>
> The example is very helpful! I basically want to do exactly that, but
> in my case, I need to show the standard NSColorPanel, not a custom
> colour picker.
>
> NSColorPanel is a modeless window, whereas your example displays a sorta-
> modal window, which allows you to assume things like the table columns
> not being reordered while the window is shown. Is this why you auto-
> close the ATPopupWindow if the user does almost anything other that pick
> a colour right away?
>
> I wondered if you might have a suggestion on how to proceed...
>
overall: you'll have to keep more state when you show the color panel. Set the target to your controller and control the "last color well" and "last row" you want to edit. Update the value as you get notifications in the controller when the color changes.
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