To answer my own question, it looks like it's done by implementing a Service.  
I've gotten it working in a quick scratch application.

--Andy

On Dec 21, 2013, at 6:06 PM, Andy Lee <ag...@mac.com> wrote:

> I know how to accept files that are dragged from Finder to the application 
> icon.  It's a matter of adding some settings to Info.plist and implementing 
> the application:openFiles: application delegate method.
> 
> This does not work for dragging URLs from a web browser -- for example, 
> dragging from Safari's URL field, or dragging an image being displayed in 
> Safari to the dock icon.  What happens is, my application:openFiles: method 
> is never called, and the URL is given back to Safari to reload.
> 
> Yet it is clearly possible for applications to accept dragging of URLs to 
> their Dock icons, because it works for other browsers.  What are those other 
> browsers doing?
> 
> I tried using a custom contentView for the dock tile, and having that view be 
> a drag destination (call registerForDraggedTypes: and implement 
> NSDraggingDestination methods).  But that didn't make any difference.
> 
> --Andy



_______________________________________________

Cocoa-dev mailing list (Cocoa-dev@lists.apple.com)

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:
https://lists.apple.com/mailman/options/cocoa-dev/archive%40mail-archive.com

This email sent to arch...@mail-archive.com

Reply via email to