Drag a window and get draggingEntered
Drag a window and get draggingEntered
- Subject: Drag a window and get draggingEntered
- From: Leonardo <email@hidden>
- Date: Sat, 11 Jan 2014 17:16:34 +0100
- Thread-topic: Drag a window and get draggingEntered
I can quite register an NSView to receive a notification (draggingEntered:)
when a file is drop over it
NSMutableArray *dragTypes = [NSMutableArray
arrayWithObjects:NSFilenamesPboardType, nil];
[myView registerForDraggedTypes:dragTypes];
I would like to get the same notification when I drag a NSWindow over that
NSView. Which PboardType should I use?
I would like to achieve the following target: when I drag a window over an
NSWiew then release the mouse button, I remove the content from the window
and I put it within the view, then I delete the window. Photoshop does a
similar task.
Any idea?
P.S. I have already tried to get the mouse position while dragging, then
detect the drop view among the others, but it looks like a dirty way to code
it.
Regards
-- Leonardo
_______________________________________________
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