Thank you. I've gotten some code together that seems to do what I want
based on that method.
On Aug 8, 2009, at 11:48 AM, Nathan Vander Wilt wrote:
On Aug 7, 2009, at 6:56 AM, bryscomat wrote:
... Now the dilemma comes when I want to get the drag and drop to
work in a specific way. I want the playlists to be able to be
dragged and placed in any order, but not above the separator. I
have achieved this using the delegate method validateDrop: and
returning DragOperationNone if the proposed child index is less
than the index of the separator. However, I also want a user to be
able to drag the items in the Singers group around in any order as
well, and this doesn't allow that. I found that if in validateDrop:
I check if the item is a singer and that the parent item is the
singers group to allow it that it works for that. How do I get both
of these to happen? If anyone could just point me in the right
direction I'll take it from there.
Take a look at the -[NSOutlineView setDropItem:dropChildIndex:]
method. You can call it from your validateDrop method to change the
proposedItem and proposedChildIndex if they are not appropriate.
hth,
-natevw
_______________________________________________
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/bryscomat%40gmail.com
This email sent to brysco...@gmail.com
_______________________________________________
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