Dragging to Folder in Dock
Dragging to Folder in Dock
- Subject: Dragging to Folder in Dock
- From: Steve Gehrman <email@hidden>
- Date: Fri, 20 Jan 2006 18:34:49 -0800
I've got a cocoa app. I'm trying to drag and drop a file to a folder
in the Dock. Nothing happens when the item is dropped.
For dragging to the Docks trash can, it's kind of a hack, but maybe
something similar is needed when dragging to a folder.
For dragging to the trash I use...
- (void)draggedImage:(NSImage *)image endedAt:(NSPoint)screenPoint
operation:(NSDragOperation)operation;
{
if (operation == NSDragOperationDelete)
[self trashTheFiles];
}
This ugly hack works, but doing something similar with dragging to a
folder is not possible. In the case of dragging to the trash, I can
safely assume that any drag that has the operation
NSDragOperationDelete is dragging to the trash can, but for dragging
to a folder, there is no way to distinguish between a drag to the
Docks folder and a drag to the Finder or another app that would
handle the drop.
Anyone solved this?
-steve
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Cocoa-dev mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden