Dropping folder on dock icon

What do I need to do to make the dock icon accept a folder? I’ve already got a special/any file type:

It’s been too long since I had problem with dropping files on the dock icon.

Identifier “public.folder” seems to do the magic :wink:
See Apple: System-Declared Uniform Type Identifiers

1 Like

I’m not on my computer to test and search my other post but I thinl you need to put the role to View (or Edit or Execute but anything else than None). I spoke about that some days ago.

1 Like

This is what I use for special/any

I had to use both the identifier/conforms to and the role:

@Thomas_ROBISSON and @TomE : thanks!

That was my question in the topic Drag and Drop on the Application Icon

It is not in the document that we have to put the Role to something else than None in order to make the application icon accept drag&drop of items.

I don’t think it is important but what I read in the file_type_group_editor doc make me set Rank to Alternate for file type any or folder.

  • Rank. Enabled only if the Role is set to Edit, View or Execute. MacOS uses rank to determine which app to use to open a file. The order of precedence is Owner, Default, Alternate. Default means this app is an opener of files of this type; this value is also used if no rank is specified. This would be appropriate for files uniquely created by your application. Owner means this app is the primary creator of files of this type. Alternate means this app is a secondary viewer of files of this type.

As my app is not the uniq creator of any files and folder, I put Rank to Alternate. But maybe I misunderstood what I read. Should I understand that if my application is the Uniq creator then I have to set the Rank to None ?

One more thing, Type, Role and Rank are in the GroupBox macOS Options , then it means this has no effect on Windows application. But it does, a double-clic on a document created by your application (on Windows) does not launch the application.exe if the Role is set to None.