git://source.jalview.org
/
jalview.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
JAL-1632 named parameters
[jalview.git]
/
src
/
jalview
/
bin
/
JalviewLite.java
diff --git
a/src/jalview/bin/JalviewLite.java
b/src/jalview/bin/JalviewLite.java
index
7f15b3e
..
7fa5147
100644
(file)
--- a/
src/jalview/bin/JalviewLite.java
+++ b/
src/jalview/bin/JalviewLite.java
@@
-38,8
+38,8
@@
import jalview.datamodel.SequenceI;
import jalview.io.AnnotationFile;
import jalview.io.AppletFormatAdapter;
import jalview.io.DataSourceType;
import jalview.io.AnnotationFile;
import jalview.io.AppletFormatAdapter;
import jalview.io.DataSourceType;
-import jalview.io.FileFormat;
import jalview.io.FileFormatI;
import jalview.io.FileFormatI;
+import jalview.io.FileFormats;
import jalview.io.FileParse;
import jalview.io.IdentifyFile;
import jalview.io.JPredFile;
import jalview.io.FileParse;
import jalview.io.IdentifyFile;
import jalview.io.JPredFile;
@@
-51,6
+51,7
@@
import jalview.javascript.JsCallBack;
import jalview.javascript.MouseOverStructureListener;
import jalview.structure.SelectionListener;
import jalview.structure.StructureSelectionManager;
import jalview.javascript.MouseOverStructureListener;
import jalview.structure.SelectionListener;
import jalview.structure.StructureSelectionManager;
+import jalview.util.ColorUtils;
import jalview.util.HttpUtils;
import jalview.util.MessageManager;
import jalview.util.HttpUtils;
import jalview.util.MessageManager;
@@
-470,7
+471,7
@@
public class JalviewLite extends Applet implements
SequenceI rs = sel.getSequenceAt(0);
start = rs.findIndex(start);
end = rs.findIndex(end);
SequenceI rs = sel.getSequenceAt(0);
start = rs.findIndex(start);
end = rs.findIndex(end);
- List<Integer> cs = csel.getSelected();
+ List<Integer> cs = new ArrayList<Integer>(csel.getSelected());
csel.clear();
for (Integer selectedCol : cs)
{
csel.clear();
for (Integer selectedCol : cs)
{
@@
-517,7
+518,7
@@
public class JalviewLite extends Applet implements
{
try
{
{
try
{
- FileFormatI theFormat = FileFormat.valueOf(format);
+ FileFormatI theFormat = FileFormats.getInstance().forName(format);
boolean seqlimits = suffix.equalsIgnoreCase(TRUE);
if (alf.viewport.getSelectionGroup() != null)
{
boolean seqlimits = suffix.equalsIgnoreCase(TRUE);
if (alf.viewport.getSelectionGroup() != null)
{
@@
-715,7
+716,7
@@
public class JalviewLite extends Applet implements
{
boolean seqlimits = suffix.equalsIgnoreCase(TRUE);
{
boolean seqlimits = suffix.equalsIgnoreCase(TRUE);
- FileFormatI theFormat = FileFormat.valueOf(format);
+ FileFormatI theFormat = FileFormats.getInstance().forName(format);
String reply = new AppletFormatAdapter().formatSequences(theFormat,
alf.viewport.getAlignment(), seqlimits);
return reply;
String reply = new AppletFormatAdapter().formatSequences(theFormat,
alf.viewport.getAlignment(), seqlimits);
return reply;
@@
-2255,6
+2256,11
@@
public class JalviewLite extends Applet implements
{
boolean result = false;
String param = applet.getParameter("jnetfile");
{
boolean result = false;
String param = applet.getParameter("jnetfile");
+ if (param == null)
+ {
+ // jnet became jpred around 2016
+ param = applet.getParameter("jpredfile");
+ }
if (param != null)
{
try
if (param != null)
{
try
@@
-2883,22
+2889,13
@@
public class JalviewLite extends Applet implements
{
return defcolour;
}
{
return defcolour;
}
- Color col = jalview.schemes.ColourSchemeProperty
- .getAWTColorFromName(colprop);
+ Color col = ColorUtils.parseColourString(colprop);
if (col == null)
{
if (col == null)
{
- try
- {
- col = new jalview.schemes.UserColourScheme(colprop).findColour('A');
- } catch (Exception ex)
- {
- System.err.println("Couldn't parse '" + colprop
- + "' as a colour for " + colparam);
- col = null;
- }
+ System.err.println("Couldn't parse '" + colprop
+ + "' as a colour for " + colparam);
}
return (col == null) ? defcolour : col;
}
return (col == null) ? defcolour : col;
-
}
public void openJalviewHelpUrl()
}
public void openJalviewHelpUrl()