import jalview.api.analysis.SimilarityParamsI;
import jalview.api.structures.JalviewStructureDisplayI;
import jalview.bin.Cache;
-import jalview.bin.Instance;
import jalview.datamodel.AlignedCodonFrame;
import jalview.datamodel.Alignment;
import jalview.datamodel.AlignmentAnnotation;
import jalview.schemes.FeatureColour;
import jalview.schemes.ResidueProperties;
import jalview.schemes.UserColourScheme;
-import jalview.structure.StructureSelectionManager;
import jalview.structures.models.AAStructureBindingModel;
import jalview.util.Format;
import jalview.util.MessageManager;
String fileName, JarOutputStream jout)
{
+ // BH: Question: What is this Dataset for, as it seems to
+ // duplicate the actual XML file data.
+
for (String dssids : dsses.keySet())
{
AlignFrame _af = dsses.get(dssids);
if (calcIdParam.getVersion().equals("1.0"))
{
final String[] calcIds = calcIdParam.getServiceURL().toArray(new String[0]);
- Jws2Instance service = Jws2Discoverer.getDiscoverer()
+ Jws2Instance service = Jws2Discoverer.getInstance()
.getPreferredServiceFor(calcIds);
if (service != null)
{
{
jarentry = jin.getNextJarEntry();
}
-
- if (jarentry != null && jarentry.getName().endsWith(".xml"))
+ String name = (jarentry == null ? null : jarentry.getName());
+ if (name != null && name.endsWith(".xml")
+ // The question here is what to do with the two
+ // .xml files in the jvp file. They are identical?
+ // && name.indexOf(" Dataset for ") < 0 // BH 2019.05.21
+ )
{
JAXBContext jc = JAXBContext
.newInstance("jalview.xml.binding.jalview");
{
// used to attempt to parse as V1 castor-generated xml
}
- if (Instance.getDesktop() != null)
+ if (Desktop.getInstance() != null)
{
- Instance.getDesktop().stopLoading();
+ Desktop.getInstance().stopLoading();
}
if (af != null)
{
*/
for (AlignFrame fr : gatherToThisFrame.values())
{
- Instance.getDesktop().gatherViews(fr);
+ Desktop.getInstance().gatherViews(fr);
}
restoreSplitFrames();
{
if (ds.getCodonFrames() != null)
{
- StructureSelectionManager
- .getStructureSelectionManager(Instance.getDesktop())
+ Desktop.getInstance().getStructureSelectionManager()
.registerMappings(ds.getCodonFrames());
}
}
reportErrors();
}
- if (Instance.getDesktop() != null)
+ if (Desktop.getInstance() != null)
{
- Instance.getDesktop().stopLoading();
+ Desktop.getInstance().stopLoading();
}
return af;
*/
for (SplitFrame sf : gatherTo)
{
- Instance.getDesktop().gatherViews(sf);
+ Desktop.getInstance().gatherViews(sf);
}
splitFrameCandidates.clear();
{
entry.setProperty(prop.getName(), prop.getValue());
}
- StructureSelectionManager
- .getStructureSelectionManager(Instance.getDesktop())
+ Desktop.getInstance().getStructureSelectionManager()
.registerPDBEntry(entry);
// adds PDBEntry to datasequence's set (since Jalview 2.10)
if (al.getSequenceAt(i).getDatasetSequence() != null)
viewport.setViewName(view.getViewName());
af.setInitialTabVisible();
}
- af.setBounds(safeInt(view.getXpos()), safeInt(view.getYpos()),
- safeInt(view.getWidth()), safeInt(view.getHeight()));
+ int x = safeInt(view.getXpos());
+ int y = safeInt(view.getYpos());
+ int w = safeInt(view.getWidth());
+ int h = safeInt(view.getHeight());
+ // // BH we cannot let the title bar go off the top
+ // if (Platform.isJS())
+ // {
+ // x = Math.max(50 - w, x);
+ // y = Math.max(0, y);
+ // }
+
+ af.setBounds(x, y, w, h);
// startSeq set in af.alignPanel.updateLayout below
af.alignPanel.updateLayout();
ColourSchemeI cs = null;