Files
test/intern
Jesse Yurkovich b030acbe9d Fix #135672: Ghost: Prefer CF_HDROP ahead of CF_TEXT during drag'n'drop
When a user starts a drag'n'drop operation, the originating application
dictates the formats carried along with it. In the context of what is
broadly supported by Blender, we actively look for "text" and "files" in
the data. In that order. This order sometimes leads to a suboptimal
choice where, for example, a drag'n'drop of a "file" is interpreted as
"text" containing just the path to the file.

This PR changes the ordering to prefer the "files" first. Two notable
applications where this matters are:
 - The Firefox download library window
 - The Perforce P4V client application

Dragging and dropping files, like say FBX or OBJ, from these two apps
now properly triggers file handler behavior. Existing behavior is best
seen in the Blender Text editor. Dragging and dropping a file from the
above apps into a Text data block will yield the raw "file:///test.ext"
text. This will no longer occur after this PR.

Other platforms might have similar concepts but I don't have the
capability of checking how they handle this type of situation. They
would have to be checked against several applications to see if they
have the same issue.

Pull Request: https://projects.blender.org/blender/blender/pulls/135939
2025-03-20 19:23:52 +01:00
..