X-Git-Url: http://source.jalview.org/gitweb/?a=blobdiff_plain;f=src%2Fjalview%2Fbin%2FJalview.java;h=272250e40f57232076afa737a076899bd7ce361a;hb=0b9d0f8eba1cec46c0b31fdd402a826e26244ff5;hp=5357e8105c885caae344c896c0f1acbb3a15712a;hpb=42833ea8bc056c9d0257cf3a835b01f271f9254e;p=jalview.git diff --git a/src/jalview/bin/Jalview.java b/src/jalview/bin/Jalview.java index 5357e81..272250e 100755 --- a/src/jalview/bin/Jalview.java +++ b/src/jalview/bin/Jalview.java @@ -1,6 +1,6 @@ /* - * Jalview - A Sequence Alignment Editor and Viewer (Version 2.6) - * Copyright (C) 2010 J Procter, AM Waterhouse, G Barton, M Clamp, S Searle + * Jalview - A Sequence Alignment Editor and Viewer (Version 2.7) + * Copyright (C) 2011 J Procter, AM Waterhouse, J Engelhardt, LM Lui, G Barton, M Clamp, S Searle * * This file is part of Jalview. * @@ -318,9 +318,14 @@ public class Jalview } } } + long progress=-1; // Finally, deal with the remaining input data. if (file != null) { + if (!headless) + { + desktop.setProgressBar("Processing commandline arguments...", progress=System.currentTimeMillis()); + } System.out.println("Opening file: " + file); if (!file.startsWith("http://")) @@ -334,10 +339,6 @@ public class Jalview } } } - if (!headless) - { - desktop.setProgressBar("Processing commandline arguments...", Jalview.class.hashCode()); - } protocol = jalview.io.AppletFormatAdapter.checkProtocol(file); @@ -510,8 +511,15 @@ public class Jalview && jalview.bin.Cache.getDefault("SHOW_STARTUP_FILE", true)) { file = jalview.bin.Cache.getDefault("STARTUP_FILE", - jalview.bin.Cache.getDefault("www.jalview.org", "http://www.jalview.org")+"/examples/exampleFile_2_3.jar"); - + jalview.bin.Cache.getDefault("www.jalview.org", "http://www.jalview.org")+"/examples/exampleFile_2_7.jar"); + if (file.equals("http://www.jalview.org/examples/exampleFile_2_3.jar")) + { + // hardwire upgrade of the startup file + file.replace("_2_3.jar","_2_7.jar"); + // and remove the stale setting + jalview.bin.Cache.removeProperty("STARTUP_FILE"); + } + protocol = "File"; if (file.indexOf("http:") > -1) @@ -562,7 +570,9 @@ public class Jalview // and finally, turn off batch mode indicator - if the desktop still exists if (desktop != null) { - desktop.setProgressBar(null, Jalview.class.hashCode()); + if (progress!=-1) { + desktop.setProgressBar(null, progress); + } desktop.setInBatchMode(false); } }