From: Jim Procter Date: Mon, 30 May 2016 11:02:44 +0000 (+0100) Subject: JAL-1552 fix JAL-2122 resolve File->string before adding to List. X-Git-Tag: Release_2_10_0~201^2 X-Git-Url: http://source.jalview.org/gitweb/?a=commitdiff_plain;h=b9545ee44e0b76df7bbaf25607500dcc7b3aa744;p=jalview.git JAL-1552 fix JAL-2122 resolve File->string before adding to List. --- diff --git a/src/jalview/gui/Desktop.java b/src/jalview/gui/Desktop.java index 94f2e82..698b164 100644 --- a/src/jalview/gui/Desktop.java +++ b/src/jalview/gui/Desktop.java @@ -3164,8 +3164,12 @@ public class Desktop extends jalview.jbgui.GDesktop implements // Works on Windows and MacOSX Cache.log.debug("Drop handled as javaFileListFlavor"); evt.acceptDrop(DnDConstants.ACTION_COPY_OR_MOVE); - files.addAll((java.util.List) t - .getTransferData(DataFlavor.javaFileListFlavor)); + for (Object file : (List) t + .getTransferData(DataFlavor.javaFileListFlavor)) + { + files.add(((File)file).toString()); + protocols.add(FormatAdapter.FILE); + } } else {