• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
Drag a window and get draggingEntered
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

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


  • Follow-Ups:
    • Re: Drag a window and get draggingEntered
      • From: Kyle Sluder <email@hidden>
  • Prev by Date: Re: stringByAddingPercentEncodingWithAllowedCharacters: and friends
  • Next by Date: Re: Drag a window and get draggingEntered
  • Previous by thread: Re: stringByAddingPercentEncodingWithAllowedCharacters: and friends
  • Next by thread: Re: Drag a window and get draggingEntered
  • Index(es):
    • Date
    • Thread