hardwired default user questionnaire url and by default will always check for a quest...
[jalview.git] / src / jalview / bin / Jalview.java
index 13e9433..6079790 100755 (executable)
@@ -122,16 +122,23 @@ public class Jalview
             desktop = new Desktop();
             desktop.setVisible(true);
             desktop.discoverer.start();
-          }
-          String url = aparser.getValue("questionnaire");
-          if (url!=null && !headless) {
-              // Start the desktop questionnaire prompter
-              Cache.log.debug("Starting questionnaire url at "+url);
-              if (url!=null) {
-                  desktop.checkForQuestionnaire(url);
-              }
-          }
+            String url = aparser.getValue("questionnaire");
+            if (url!=null) {
+                // Start the desktop questionnaire prompter with the specified questionnaire
+                Cache.log.debug("Starting questionnaire url at "+url);
+                desktop.checkForQuestionnaire(url);
+            } else {
+                if (Cache.getProperty("NOQUESTIONNAIRES")==null) {
+                    // Start the desktop questionnaire prompter with the specified questionnaire
+                    // String defurl = "http://anaplog.compbio.dundee.ac.uk/cgi-bin/questionnaire.pl"; // 
+                    String defurl = "http://www.jalview.org/cgi-bin/questionnaire.pl";
+                    Cache.log.debug("Starting questionnaire with default url: "+defurl);
+                    desktop.checkForQuestionnaire(defurl);
+                        
+                }
+            }
 
+          }
 
          String file = null, protocol = null, format = null, data=null;
          jalview.io.FileLoader fileLoader = new jalview.io.FileLoader();