progressBars.put(lId, progressPanel);
}
// update GUI
- setMenusForViewport();
+ // setMenusForViewport();
validate();
}
sortByTreeMenu.add(item);
}
}
+
public boolean sortBy(AlignmentOrder alorder, String undoname)
{
- SequenceI[] oldOrder = viewport.getAlignment()
- .getSequencesArray();
+ SequenceI[] oldOrder = viewport.getAlignment().getSequencesArray();
AlignmentSorter.sortBy(viewport.getAlignment(), alorder);
- if (undoname!=null)
+ if (undoname != null)
{
- addHistoryItem(new OrderCommand(undoname, oldOrder, viewport.alignment));
+ addHistoryItem(new OrderCommand(undoname, oldOrder,
+ viewport.alignment));
}
alignPanel.paintAlignment(true);
return true;
}
+
/**
* Work out whether the whole set of sequences or just the selected set will
* be submitted for multiple alignment.
featuresFile = new FeaturesFile(file, type)
.parse(viewport.alignment.getDataset(),
alignPanel.seqPanel.seqCanvas.getFeatureRenderer().featureColours,
- false,jalview.bin.Cache.getDefault("RELAXEDSEQIDMATCHING", false));
+ false, jalview.bin.Cache.getDefault(
+ "RELAXEDSEQIDMATCHING", false));
} catch (Exception ex)
{
ex.printStackTrace();
alignPanel.paintAlignment(true);
}
}
+
+ /**
+ * make the given alignmentPanel the currently selected tab
+ *
+ * @param alignmentPanel
+ */
+ public void setDisplayedView(AlignmentPanel alignmentPanel)
+ {
+ if (!viewport.getSequenceSetId().equals(
+ alignmentPanel.av.getSequenceSetId()))
+ {
+ throw new Error(
+ "Implementation error: cannot show a view from another alignment in an AlignFrame.");
+ }
+ if (tabbedPane != null
+ & alignPanels.indexOf(alignmentPanel) != tabbedPane.getSelectedIndex())
+ {
+ tabbedPane.setSelectedIndex(alignPanels.indexOf(alignmentPanel));
+ }
+ }
}
class PrintThread extends Thread