X-Git-Url: http://source.jalview.org/gitweb/?a=blobdiff_plain;f=src%2Fjalview%2Fjbgui%2FGAlignFrame.java;h=7caf7ea3fec3e674a51dbba6dd3921d267a92384;hb=53e0350c1c4464442938e4bace4e85bdbca665be;hp=3aebcda54ec76d0bceb6e9ee25f18e6c9a7fc490;hpb=578886777f32414fbf954ba86328c9943a64bccb;p=jalview.git diff --git a/src/jalview/jbgui/GAlignFrame.java b/src/jalview/jbgui/GAlignFrame.java index 3aebcda..7caf7ea 100755 --- a/src/jalview/jbgui/GAlignFrame.java +++ b/src/jalview/jbgui/GAlignFrame.java @@ -601,9 +601,6 @@ public class GAlignFrame extends JInternalFrame hideAllAnnotations_actionPerformed(true, false); } }); - SequenceAnnotationOrder sortAnnotationsBy = SequenceAnnotationOrder - .valueOf(Cache.getDefault(Preferences.SORT_ANNOTATIONS, - SequenceAnnotationOrder.NONE.name())); sortAnnBySequence = new JCheckBoxMenuItem( MessageManager.getString("label.sort_annotations_by_sequence")); sortAnnByLabel = new JCheckBoxMenuItem( @@ -615,7 +612,7 @@ public class GAlignFrame extends JInternalFrame public void actionPerformed(ActionEvent e) { setAnnotationSortOrder(SequenceAnnotationOrder.SEQUENCE_AND_LABEL); - sortAnnotations(); + sortAnnotations(false); } }); sortAnnByLabel.addActionListener(new ActionListener() @@ -624,7 +621,7 @@ public class GAlignFrame extends JInternalFrame public void actionPerformed(ActionEvent e) { setAnnotationSortOrder(SequenceAnnotationOrder.LABEL_AND_SEQUENCE); - sortAnnotations(); + sortAnnotations(false); } }); colourTextMenuItem = new JCheckBoxMenuItem( @@ -882,7 +879,7 @@ public class GAlignFrame extends JInternalFrame { if (setShowAutoCalculatedAbove(showAutoFirst.isSelected())) { - sortAnnotations(); + sortAnnotations(true); } } }); @@ -894,7 +891,7 @@ public class GAlignFrame extends JInternalFrame { if (setShowAutoCalculatedAbove(!showAutoLast.isSelected())) { - sortAnnotations(); + sortAnnotations(true); } } }); @@ -2012,11 +2009,12 @@ public class GAlignFrame extends JInternalFrame } /** - * Action on clicking sort annotations by type. + * Action on clicking sort annotations by type, or change position of + * autocalculated annotation * - * @param sortOrder + * @param autoCalcOnly */ - protected void sortAnnotations() + protected void sortAnnotations(boolean autoCalcOnly) { }