public void addHistoryItem(CommandI command)
{
- historyList.push(command);
- redoList.clear();
- updateEditMenuBar();
-
- viewport.hasHiddenColumns = viewport.colSel.getHiddenColumns()!=null;
+ if(command.getSize()>0)
+ {
+ historyList.push(command);
+ redoList.clear();
+ updateEditMenuBar();
+ viewport.hasHiddenColumns = viewport.colSel.getHiddenColumns() != null;
+ }
}
viewport.selectionGroup);
}
+ statusBar.setText("Removed "+trimRegion.getSize()+" columns.");
+
+
addHistoryItem(trimRegion);
Vector groups = viewport.alignment.getGroups();
seqs = viewport.alignment.getSequencesArray();
- addHistoryItem(new RemoveGapColCommand("Remove Gapped Columns",
- seqs,
- start, end,
- viewport.getGapCharacter()));
+ RemoveGapColCommand removeGapCols =
+ new RemoveGapColCommand("Remove Gapped Columns",
+ seqs,
+ start, end,
+ viewport.getGapCharacter());
+
+ addHistoryItem(removeGapCols);
+
+ statusBar.setText("Removed "+removeGapCols.getSize()+" empty columns.");
//This is to maintain viewport position on first residue
//of first sequence