What about a category on NSPasteboard that uses an associated object to store stuff in the NSDraggingInfo?
Dave Sent from my iPhone On Jun 10, 2010, at 12:12 AM, Graham Cox <graham....@bigpond.com> wrote: > I'm implementing drag and drop in an outline view. > > I implement –outlineView:validateDrop:proposedItem:proposedChildIndex: to > return one of several drag operation constants depending on combinations of > source, destination and the source mask. For example the operation can be a > move or a copy depending on certain things, but <option> modifier key always > forces a copy. That works and the cursor badging correctly reflects the > intentions of the drag. > > In –outlineView:acceptDrop:item:childIndex: I can work out much the same set > of conditions as above and mostly do the right thing, but since a move or a > copy is equally likely, I need a way to determine what the last drag > operation returned during validation actually was. There doesn't seem to be a > way to do this by requesting it from any of the parameters passed to that > method. How can I get that? > > I could easily store the last value I returned in an ivar in my controller > but it seems that there should be a way to just ask the drag system for it > without this being necessary. > > > --Graham > > > _______________________________________________ > > 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/davedelong%40me.com > > This email sent to davedel...@me.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