Merge branch 'develop' into tasks/JAL-3311_removeVamsasMenu
[jalview.git] / src / jalview / bin / Jalview.java
index 86499c8..ca2a584 100755 (executable)
@@ -107,7 +107,7 @@ public class Jalview
         perms.add(new AllPermission());
         return (perms);
       }
-    
+
       @Override
       public void refresh()
       {
@@ -124,8 +124,8 @@ public class Jalview
   class FeatureFetcher
   {
     /*
-     * TODO: generalise to track all jalview events to orchestrate batch
-     * processing events.
+     * TODO: generalise to track all jalview events to orchestrate batch processing
+     * events.
      */
 
     private int queued = 0;
@@ -183,7 +183,7 @@ public class Jalview
    * main class for Jalview application
    * 
    * @param args
-   *          open <em>filename</em>
+   *               open <em>filename</em>
    */
   public static void main(String[] args)
   {
@@ -205,23 +205,6 @@ public class Jalview
     // report Jalview version
     Cache.loadBuildProperties(true);
 
-    String appdirString = System.getProperty("getdownappdir");
-    if (appdirString != null && appdirString.length() > 0)
-    {
-      final File appdir = new File(appdirString);
-      new Thread()
-      {
-        @Override
-        public void run()
-        {
-          LaunchUtil.upgradeGetdown(
-                  new File(appdir, "getdown-launcher-old.jar"),
-                  new File(appdir, "getdown-launcher.jar"),
-                  new File(appdir, "getdown-launcher-new.jar"));
-        }
-      }.start();
-
-    }
     ArgsParser aparser = new ArgsParser(args);
     boolean headless = false;
 
@@ -325,8 +308,9 @@ public class Jalview
                   "Failed to set QuaQua look and feel: " + e.toString());
         }
       }
-      if (lookAndFeel == null || !(lookAndFeel.getClass()
-              .isAssignableFrom(UIManager.getLookAndFeel().getClass()))
+      if (lookAndFeel == null
+              || !(lookAndFeel.getClass().isAssignableFrom(
+                      UIManager.getLookAndFeel().getClass()))
               || !UIManager.getLookAndFeel().getClass().toString()
                       .toLowerCase().contains("quaqua"))
       {
@@ -344,10 +328,10 @@ public class Jalview
     }
 
     /*
-     * configure 'full' SO model if preferences say to, 
-     * else use the default (SO Lite)
+     * configure 'full' SO model if preferences say to, else use the default (SO
+     * Lite)
      */
-    if (Cache.getDefault("USE_FULL_SO", false))
+    if (Cache.getDefault("USE_FULL_SO", true))
     {
       SequenceOntologyFactory.setInstance(new SequenceOntology());
     }
@@ -422,6 +406,25 @@ public class Jalview
       BioJsHTMLOutput.updateBioJS();
     }
 
+    // Move any new getdown-launcher-new.jar into place over old
+    // getdown-launcher.jar
+    String appdirString = System.getProperty("getdownappdir");
+    if (appdirString != null && appdirString.length() > 0)
+    {
+      final File appdir = new File(appdirString);
+      new Thread()
+      {
+        @Override
+        public void run()
+        {
+          LaunchUtil.upgradeGetdown(
+                  new File(appdir, "getdown-launcher-old.jar"),
+                  new File(appdir, "getdown-launcher.jar"),
+                  new File(appdir, "getdown-launcher-new.jar"));
+        }
+      }.start();
+    }
+
     String file = null, data = null;
     FileFormatI format = null;
     DataSourceType protocol = null;
@@ -487,9 +490,8 @@ public class Jalview
         {
           data.replaceAll("%20", " ");
 
-          ColourSchemeI cs = ColourSchemeProperty
-                  .getColourScheme(af.getViewport(),
-                          af.getViewport().getAlignment(), data);
+          ColourSchemeI cs = ColourSchemeProperty.getColourScheme(
+                  af.getViewport(), af.getViewport().getAlignment(), data);
 
           if (cs != null)
           {
@@ -819,10 +821,10 @@ public class Jalview
    * Locate the given string as a file and pass it to the groovy interpreter.
    * 
    * @param groovyscript
-   *          the script to execute
+   *                         the script to execute
    * @param jalviewContext
-   *          the Jalview Desktop object passed in to the groovy binding as the
-   *          'Jalview' object.
+   *                         the Jalview Desktop object passed in to the groovy
+   *                         binding as the 'Jalview' object.
    */
   private void executeGroovyScript(String groovyscript, AlignFrame af)
   {
@@ -951,8 +953,8 @@ public class Jalview
   }
 
   /**
-   * Quit method delegates to Desktop.quit - unless running in headless mode
-   * when it just ends the JVM
+   * Quit method delegates to Desktop.quit - unless running in headless mode when
+   * it just ends the JVM
    */
   public void quit()
   {