<AWT Dev> 4899516: Transferable has no DataFlavors when dragging from Gnome window to Swing
Denis S. Fokin
Denis.Fokin at Sun.COM
Mon Oct 1 10:53:57 PDT 2007
> Ok I'm sorry for arguing so much. Less talk more code :-).
> This weekend I started writing code for URIListFlavor, but I quickly
> realized another problem. If you deprecate javaFileListFlavor and use
> URIListFlavor, the problem still exists in the opposite direction:
> when Java is the drag source and a native application the drop target,
> on non-XDnD implementations you still have to do lossy conversion from
> URIs to Files and somehow disregard non-local-file URIs, and possibly
> provide the native application with an empty file list.
> Any ideas?
Currently, AWT supports OLE Drag & Drop protocol on Windows platform,
XDnD and Motif Drag & Drop protocols on UNIX-like platforms.
In case if some application asks our java source about available
formats, we will provide javaFileListFlavor only if among our data files
On the basis of a value returned by uri.getScheme() method we could
understand whether we should provide javaFileListFlavor for native
In this case we will not publish native flavors for file list (e.g.
HDROP on windows).
I suppose, the same scenario should works for java intra-jvm transfer.
To summarize, as far as we have all information on drag source we can
publish only data flavors which we really have.
But I could miss out something, so give me know where the problems arise.
More information about the awt-dev