NSTableView dragging to the finder - NSDragOperation
NSTableView dragging to the finder - NSDragOperation
- Subject: NSTableView dragging to the finder - NSDragOperation
- From: Don Messerli <email@hidden>
- Date: Mon, 28 Jul 2008 08:48:07 -0700 (PDT)
I have a subclass of NSTableView in which I'm implementing drag and drop to the finder. Everything is basically working. However, when my class gets the call draggedImage:endedAt:operation:, operation is NSDragOperationGeneric (for a copy or move) or NSDragOperationDelete (for a delete). I'm expecting to get NSDragOperationCopy, NSDragOperationMove or NSDragOperationDelete depending on the modified keys and where the user dragged the image.
I am using NSFilesPromisePboardType for the pasteboard as the files are remote.
Here are some code snippets to answer some possible queries in advance...
- (NSDragOperation)draggingSourceOperationMaskForLocal:(BOOL)isLocal
{
if (isLocal) return NSDragOperationNone;
else return NSDragOperationCopy | NSDragOperationMove | NSDragOperationDelete;
}
- (BOOL)ignoreModifierKeysWhileDragging
{
return NO;
}
Don
_______________________________________________
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