*\r
* @param align The alignment object to sort\r
*/\r
- public static void sortByID(AlignmentI align)\r
+ public static void sortByID(AlignmentI align, boolean dbprefix)\r
{\r
int nSeq = align.getHeight();\r
\r
\r
for (int i = 0; i < nSeq; i++)\r
{\r
- ids[i] = align.getSequenceAt(i).getName();\r
+ ids[i] = align.getSequenceAt(i).getDisplayId(dbprefix, false);\r
seqs[i] = align.getSequenceAt(i);\r
}\r
\r
{\r
addHistoryItem(new HistoryItem("ID Sort", viewport.alignment,\r
HistoryItem.SORT));\r
- AlignmentSorter.sortByID(viewport.getAlignment());\r
+ AlignmentSorter.sortByID(viewport.getAlignment(), viewport.showDBPrefix);\r
alignPanel.repaint();\r
}\r
\r
\r
}\r
\r
+ public AlignViewport getViewport()\r
+ {\r
+ return viewport;\r
+ }\r
+\r
+\r
/**\r
* DOCUMENT ME!\r
*\r
{\r
addHistoryItem(new HistoryItem("ID Sort", viewport.alignment,\r
HistoryItem.SORT));\r
- AlignmentSorter.sortByID(viewport.getAlignment());\r
+ AlignmentSorter.sortByID(viewport.getAlignment(), viewport.showDBPrefix);\r
alignPanel.repaint();\r
}\r
\r
if (value == JalviewFileChooser.APPROVE_OPTION)\r
{\r
jalview.io.VamsasDatastore vs = new jalview.io.VamsasDatastore(viewport);\r
- vs.store(chooser.getSelectedFile().getAbsolutePath()\r
- );\r
+ //vs.store(chooser.getSelectedFile().getAbsolutePath() );\r
+ vs.storeJalview( chooser.getSelectedFile().getAbsolutePath(), this);\r
}\r
}\r
\r