Re: Custom drag image for NSTableView selections
Re: Custom drag image for NSTableView selections
- Subject: Re: Custom drag image for NSTableView selections
- From: Graham Cox <email@hidden>
- Date: Fri, 12 Jul 2013 15:27:43 +1000
On 12/07/2013, at 2:29 PM, email@hidden wrote:
> But will be adding drag to move and drag to copy between collections, as well as drag to external for copying a text or image representation.
Those externals would be additional (standard) drag types.
> But to support the other kinds of drag ops, I may need to go with a heavier weight pasteboard entry? ( since there's no way to preemptively know the destination)
At the time of the drop you do know, and for those types that are moving out of the app, you supply the data at that time (promise data). This avoids the need to "load up" the pasteboard with a lot of data (potentially expensively) ahead of time just on the offchance that one of them will be needed. You declare your various different types ahead of time, but not the actual data until actually needed.
> Last for polish I need to figure out the animation of row reordering when drag is internal. But that's not the highest priority at the moment.
NSTableView has methods for performing the animation, once you know which rows are moving where. That is handled as part of the final step of the drop, which is long after the drag manager has done its bit.
--Graham
_______________________________________________
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