JAL-3328 improvement to the EQinvoke code
authorBen Soares <bsoares@dundee.ac.uk>
Sat, 22 Jun 2019 09:14:39 +0000 (10:14 +0100)
committerBen Soares <bsoares@dundee.ac.uk>
Sat, 22 Jun 2019 09:14:39 +0000 (10:14 +0100)
getdown/lib/getdown-core.jar
getdown/lib/getdown-launcher.jar
getdown/src/getdown/launcher/src/main/java/com/threerings/getdown/launcher/Getdown.java
getdown/src/getdown/mvn_cmd
j11lib/getdown-core.jar
j8lib/getdown-core.jar

index f435ab6..ced5304 100644 (file)
Binary files a/getdown/lib/getdown-core.jar and b/getdown/lib/getdown-core.jar differ
index 5533beb..8a383e7 100644 (file)
Binary files a/getdown/lib/getdown-launcher.jar and b/getdown/lib/getdown-launcher.jar differ
index bb018dd..fdf4b15 100644 (file)
@@ -1108,18 +1108,25 @@ public abstract class Getdown extends Thread
     
     // Asynchronous or synchronous progress updates
     protected void EQinvoke(Runnable r) {
+      
       try {
         readConfig(false);
-        if (_ifc.progressSync) {
+      } catch (Exception e) {
+        log.warning("Could't read config when invoking GUI action", "Exception", e.getMessage());
+      }
+      if (! (_ifc == null) && _ifc.progressSync) {
+        try {
           EventQueue.invokeAndWait(r);
-        } else {
+        } catch (Exception e) {
+          log.warning("Tried to invokeAndWait but couldn't. Going to invokeLater instead", "Exception", e.getMessage());
           EventQueue.invokeLater(r);
         }
-      } catch (Exception e) {
+      } else {
         EventQueue.invokeLater(r);
       }
+      
     }
-
+    
     protected Application _app;
     protected Application.UpdateInterface _ifc = new Application.UpdateInterface(Config.EMPTY);
 
index bf2db45..016633a 100755 (executable)
@@ -17,8 +17,8 @@ perl -p -i -e 's|(<version>)[^<]*JVL[^<]*(</version>)|${1}$ENV{VERSION}${2}|;' p
 mvn clean package -Dgetdown.host.whitelist="jalview.org,*.jalview.org"
 RET=$?
 if [ x$RET = x0 ]; then
-  cp launcher/target/getdown-launcher-$VERSION.jar ../../../getdown/lib/getdown-launcher.jar
-  cp core/target/getdown-core-$VERSION.jar ../../../getdown/lib/getdown-core.jar
-  cp core/target/getdown-core-$VERSION.jar ../../../j8lib/getdown-core.jar
-  cp core/target/getdown-core-$VERSION.jar ../../../j11lib/getdown-core.jar 
+  cp launcher/target/getdown-launcher-$VERSION.jar ../../../getdown/lib/getdown-launcher.jar && echo "Copied getdown-launcher.jar to getdown/lib"
+  cp core/target/getdown-core-$VERSION.jar ../../../getdown/lib/getdown-core.jar && echo "Copied getdown-core.jar to getdown/lib"
+  cp core/target/getdown-core-$VERSION.jar ../../../j8lib/getdown-core.jar && echo "Copied getdown-core.jar to j8lib"
+  cp core/target/getdown-core-$VERSION.jar ../../../j11lib/getdown-core.jar && echo "Copied getdown-core.jar to j11lib"
 fi
index f435ab6..ced5304 100644 (file)
Binary files a/j11lib/getdown-core.jar and b/j11lib/getdown-core.jar differ
index f435ab6..ced5304 100644 (file)
Binary files a/j8lib/getdown-core.jar and b/j8lib/getdown-core.jar differ