• 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
Re: dragging images to the finder
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: dragging images to the finder


  • Subject: Re: dragging images to the finder
  • From: Nick Zitzmann <email@hidden>
  • Date: Mon, 12 Jan 2009 00:13:57 -0700


On Jan 11, 2009, at 9:48 PM, Eric Smith wrote:

I'm trying to get drag-and-drop to work, using the finder as a destination. I can drag my files into mail using NSTIFFPboardType. My draggingSourceOperationMaskForLocal returns NSDragOperationEvery. But, when I drag my file onto a finder window, I get no icon at all... no little green plus indicating a copy. My pasteboard: provideDataForType: is never called by the finder. How the heck to I get the finder to accept a drop??


Assuming you are trying to create a picture file here, you have to use the pasteboard type "CorePasteboardFlavorType 0x6675726C" to get the Finder to accept the drag, and it must contain a file URL string pointing to the source image that you must write to the disk somewhere. Or you could do a file promise drag instead; that's a lot easier now than it used to be a while ago.

Nick Zitzmann
<http://www.chronosnet.com/>



_______________________________________________

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


References: 
 >dragging images to the finder (From: Eric Smith <email@hidden>)

  • Prev by Date: Re: Trust, but verify - OCUnit testing of Target-Action Connections
  • Next by Date: Remove Items From NSSet (safely)
  • Previous by thread: dragging images to the finder
  • Next by thread: Re: dragging images to the finder
  • Index(es):
    • Date
    • Thread