JAL-3446 from applet -- reload; also fixes some repaint issues
[jalview.git] / src / jalview / io / AppletFormatAdapter.java
index 6db04a0..f01bfdc 100755 (executable)
@@ -158,9 +158,7 @@ public class AppletFormatAdapter
   {
 
     this.selectedFile = selectedFile;
-    if (selectedFile != null)
-      this.inFile = selectedFile.getPath();
-    this.inFile = file;
+    inFile = (selectedFile == null ? file : selectedFile.getPath());
     try
     {
       if (fileFormat.isStructureFile())
@@ -435,7 +433,9 @@ public class AppletFormatAdapter
   public static DataSourceType checkProtocol(Object dataObject)
   {
     if(dataObject instanceof File)
+    {
       return DataSourceType.FILE;
+    }
     
     String data = dataObject.toString();
     DataSourceType protocol = DataSourceType.PASTE;
@@ -456,6 +456,10 @@ public class AppletFormatAdapter
     return protocol;
   }
 
+  /**
+   * @param args
+   * @j2sIgnore
+   */
   public static void main(String[] args)
   {
     int i = 0;