JAL-3310 JAL-3300 two getdown fixes merged
authorBen Soares <bsoares@dundee.ac.uk>
Mon, 17 Jun 2019 19:15:00 +0000 (20:15 +0100)
committerBen Soares <bsoares@dundee.ac.uk>
Mon, 17 Jun 2019 19:15:00 +0000 (20:15 +0100)
1  2 
build.gradle
getdown/lib/getdown-core-1.8.3-SNAPSHOT.jar
getdown/lib/getdown-launcher.jar
getdown/src/getdown/launcher/src/main/java/com/threerings/getdown/launcher/GetdownApp.java
getdown/src/getdown/pom.xml
j11lib/getdown-core.jar
j8lib/getdown-core.jar

diff --combined build.gradle
@@@ -97,6 -97,19 +97,19 @@@ if (JAVA_VERSION.equals("1.8")) 
      '--module-path', ext.modules_compileClasspath.asPath,
      '--add-modules', j11modules
    ]
+ } else if (JAVA_VERSION.equals("12") || JAVA_VERSION.equals("13")) {
+   JAVA_INTEGER_VERSION = JAVA_VERSION
+   libDir = j11libDir
+   libDistDir = j11libDir
+   compile_source_compatibility = JAVA_VERSION
+   compile_target_compatibility = JAVA_VERSION
+   getdown_alt_java_min_version = getdown_alt_java11_min_version
+   getdown_alt_multi_java_location = getdown_alt_java11_txt_multi_java_location
+   eclipse_java_runtime_name = "JavaSE-11"
+   additional_compiler_args += [
+     '--module-path', ext.modules_compileClasspath.asPath,
+     '--add-modules', j11modules
+   ]
  } else {
    throw new GradleException("JAVA_VERSION=$JAVA_VERSION not currently supported by Jalview")
  }
@@@ -419,9 -432,9 +432,9 @@@ cleanTest 
    delete cloverInstrDir
  }
  
 +// format is a string like date.format("dd MMMM yyyy")
  def getDate(format) {
    def date = new Date()
 -  //return date.format("dd MMMM yyyy")
    return date.format(format)
  }
  
@@@ -453,9 -466,9 +466,9 @@@ task createBuildProperties(type: WriteP
    inputs.dir("$jalviewDir/$resourceDir")
    outputFile "$classes/$buildPropertiesFile"
    // taking time specific comment out to allow better incremental builds
 -  //comment "--Jalview Build Details--\n"+getDate("yyyy-MM-dd HH:mm:ss")
 -  comment "--Jalview Build Details--\n"+getDate("yyyy-MM-dd")
 -  property "BUILD_DATE", getDate("dd MMMM yyyy")
 +  comment "--Jalview Build Details--\n"+getDate("yyyy-MM-dd HH:mm:ss")
 +  //comment "--Jalview Build Details--\n"+getDate("yyyy-MM-dd")
 +  property "BUILD_DATE", getDate("HH:mm:ss dd MMMM yyyy")
    property "VERSION", JALVIEW_VERSION
    property "INSTALLATION", INSTALLATION+" git-commit:"+project.ext.gitHash+" ["+project.ext.gitBranch+"]"
    outputs.file(outputFile)
index 0c41ec2,2949778..bbeb351
Binary files differ
index bf83b3b,e57d4e8..6323dc9
Binary files differ
@@@ -27,6 -27,7 +27,6 @@@ import javax.swing.JFrame
  import javax.swing.KeyStroke;
  import javax.swing.WindowConstants;
  
 -import com.install4j.api.launcher.StartupNotification;
  import com.samskivert.swing.util.SwingUtil;
  import com.threerings.getdown.data.Application;
  import com.threerings.getdown.data.EnvConfig;
@@@ -34,7 -35,6 +34,7 @@@ import com.threerings.getdown.data.SysP
  import com.threerings.getdown.util.LaunchUtil;
  import com.threerings.getdown.util.StringUtil;
  import static com.threerings.getdown.Log.log;
 +import jalview.bin.StartupNotificationListener;
  
  /**
   * The main application entry point for Getdown.
@@@ -94,16 -94,18 +94,16 @@@ public class GetdownAp
  
      try
      {
 -      StartupNotification.registerStartupListener(
 -              new StartupNotification.Listener() {
 -                @Override
 -                public void startupPerformed(String parameters)
 -                { 
 -                  log.warning("StartupNotification.Listener.startupPerformed: '"+parameters+"'");
 -                  setStartupFilesParameterString(parameters);
 -                }
 -              });
 +      jalview.bin.StartupNotificationListener.setListener();
      } catch (Exception e)
      {
        e.printStackTrace();
 +    } catch (NoClassDefFoundError e)
 +    {
 +      log.warning("Starting without install4j classes");
 +    } catch (Throwable t)
 +    {
 +      t.printStackTrace();
      }
      
      // record a few things for posterity
            log.warning("Failed to set background", "bg", _ifc.background, e);
          }
  
-         if (_ifc.iconImages != null) {
+         if (_ifc.iconImages != null && _ifc.iconImages.size() > 0) {
            ArrayList<Image> icons = new ArrayList<>();
            for (String path : _ifc.iconImages) {
              Image img = loadImage(path);
@@@ -65,7 -65,7 +65,7 @@@
                <groupId>com.install4j</groupId>
                <artifactId>install4j-runtime</artifactId>
                <version>7.0.11</version>
 -              <!--<scope>provided</scope>-->
 +              <scope>provided</scope>
        </dependency>
    </dependencies>
  
          <plugin>
            <groupId>org.apache.maven.plugins</groupId>
            <artifactId>maven-compiler-plugin</artifactId>
-           <version>3.7.0</version>
+           <version>3.8.1</version>
            <configuration>
-             <source>1.7</source>
-             <target>1.7</target>
+             <source>1.8</source>
+             <target>1.8</target>
              <fork>true</fork>
              <showDeprecation>true</showDeprecation>
              <showWarnings>true</showWarnings>
diff --combined j11lib/getdown-core.jar
index 0c41ec2,2949778..bbeb351
Binary files differ
diff --combined j8lib/getdown-core.jar
index 0c41ec2,2949778..bbeb351
Binary files differ