From f2cc1f45f6d4bdc47a491b01aa7b0f2b2d9ed1bd Mon Sep 17 00:00:00 2001 From: tcofoegbu Date: Wed, 11 Nov 2015 14:21:20 +0000 Subject: [PATCH] JAL-1479 JAL-1957 Added code to enable simultaneous highlight of multiple atoms positions in all chains --- src/jalview/ext/jmol/JalviewJmolBinding.java | 17 ++++++++++------- 1 file changed, 10 insertions(+), 7 deletions(-) diff --git a/src/jalview/ext/jmol/JalviewJmolBinding.java b/src/jalview/ext/jmol/JalviewJmolBinding.java index b464c94..a1b6917 100644 --- a/src/jalview/ext/jmol/JalviewJmolBinding.java +++ b/src/jalview/ext/jmol/JalviewJmolBinding.java @@ -552,6 +552,7 @@ public abstract class JalviewJmolBinding extends AAStructureBindingModel System.out.println("JMOL CREATE IMAGE"); } + @Override public String createImage(String fileName, String type, Object textOrBytes, int quality) { @@ -559,6 +560,7 @@ public abstract class JalviewJmolBinding extends AAStructureBindingModel return null; } + @Override public String eval(String strEval) { // System.out.println(strEval); @@ -569,11 +571,13 @@ public abstract class JalviewJmolBinding extends AAStructureBindingModel // End StructureListener // ////////////////////////// + @Override public float[][] functionXY(String functionName, int x, int y) { return null; } + @Override public float[][][] functionXYZ(String functionName, int nx, int ny, int nz) { // TODO Auto-generated method stub @@ -737,6 +741,11 @@ public abstract class JalviewJmolBinding extends AAStructureBindingModel { if (atoms != null) { + if (resetLastRes.length() > 0) + { + viewer.evalStringQuiet(resetLastRes.toString()); + resetLastRes.setLength(0); + } for (AtomSpec atom : atoms) { highlightAtom(atom.getAtomIndex(), atom.getPdbResNum(), @@ -768,17 +777,10 @@ public abstract class JalviewJmolBinding extends AAStructureBindingModel } jmolHistory(false); - // if (!pdbfile.equals(pdbentry.getFile())) - // return; - if (resetLastRes.length() > 0) - { - viewer.evalStringQuiet(resetLastRes.toString()); - } StringBuilder cmd = new StringBuilder(64); cmd.append("select " + pdbResNum); // +modelNum - resetLastRes.setLength(0); resetLastRes.append("select " + pdbResNum); // +modelNum cmd.append(":"); @@ -1264,6 +1266,7 @@ public abstract class JalviewJmolBinding extends AAStructureBindingModel */ public abstract void sendConsoleMessage(String strStatus); + @Override public void setCallbackFunction(String callbackType, String callbackFunction) { -- 1.7.10.2