\r
String format = new jalview.io.IdentifyFile().Identify(args[0],AppletFormatAdapter.FILE);\r
\r
- SequenceI[] sequences = null;\r
+ Alignment al = null;\r
try{\r
- sequences = new AppletFormatAdapter().readFile(args[0], AppletFormatAdapter.FILE, format);\r
+ al = new AppletFormatAdapter().readFile(args[0], AppletFormatAdapter.FILE, format);\r
}catch(java.io.IOException ex)\r
{\r
ex.printStackTrace();\r
}\r
- if ( (sequences != null) && (sequences.length > 0))\r
+ if ( (al != null) && (al.getHeight() > 0))\r
{\r
- AlignFrame af = new AlignFrame(new Alignment(sequences), null, args[0], false);\r
+ AlignFrame af = new AlignFrame(al, null, args[0], false);\r
af.statusBar.setText("Successfully loaded file " + args[0]);\r
}\r
}\r
\r
public void run()\r
{\r
- SequenceI[] sequences = null;\r
+ Alignment al = null;\r
try{\r
- sequences = new AppletFormatAdapter().readFile(file, protocol,\r
+ al = new AppletFormatAdapter().readFile(file, protocol,\r
format);\r
}catch(java.io.IOException ex)\r
{\r
ex.printStackTrace();\r
}\r
- if ((sequences != null) && (sequences.length > 0))\r
+ if ((al != null) && (al.getHeight() > 0))\r
{\r
- currentAlignFrame = new AlignFrame(new Alignment(sequences),\r
+ currentAlignFrame = new AlignFrame(al,\r
applet,\r
file,\r
embedded);\r