JAL-3032 JalviewJS2 converts url query parameters to 'applet' args
authorgmungoc <g.m.carstairs@dundee.ac.uk>
Mon, 25 Feb 2019 15:24:57 +0000 (15:24 +0000)
committergmungoc <g.m.carstairs@dundee.ac.uk>
Mon, 25 Feb 2019 15:24:57 +0000 (15:24 +0000)
src/jalview/bin/JalviewJS2.java

index eff5334..0a02a8d 100644 (file)
@@ -25,20 +25,23 @@ public class JalviewJS2
      *            "examples/exampleFeatures.txt"];
      */
 
-         
-           /**
-            * @j2sNative
-            * 
-            *            thisApplet.__Info.args =
-            *            ["open","examples/jaxbtest.jvx"];
-            */
-
+    /**
+     * @j2sNative
+     * 
+     *         hr = decodeURI(document.location.href);
+     *  pos = hr.indexOf("?");
+     *  // set space-delimited query parameters as arguments to Jalview main
+     *  if (pos > 0)
+     *  {
+     *     thisApplet.__Info.args = hr.substring(pos+1).split(" ");
+     *  }
+     */
   }
 
   public static void main(String[] args) throws Exception
   {
     Jalview.main(args);
-       showFocusTimer();
+       //showFocusTimer();
 }
 
 protected static int focusTime = 0;