X-Git-Url: http://source.jalview.org/gitweb/?a=blobdiff_plain;f=src%2Fjalview%2Fgui%2FAnnotationColourChooser.java;h=384635b5dcbe2df56c25e5687d5c1896e8e3050a;hb=10cb8ffc129d24c1a4bc506199d2e144ec99c038;hp=8d123bbe25dd2a7ad95fa084a108162bb95a491d;hpb=a9c0ba9fb445e38918d3e20fb9eba72eb641b4ed;p=jalview.git diff --git a/src/jalview/gui/AnnotationColourChooser.java b/src/jalview/gui/AnnotationColourChooser.java index 8d123bb..384635b 100644 --- a/src/jalview/gui/AnnotationColourChooser.java +++ b/src/jalview/gui/AnnotationColourChooser.java @@ -79,7 +79,7 @@ public class AnnotationColourChooser extends AnnotationRowFilter oldcs = av.getGlobalColourScheme(); if (av.getAlignment().getGroups() != null) { - oldgroupColours = new Hashtable(); + oldgroupColours = new Hashtable<>(); for (SequenceGroup sg : ap.av.getAlignment().getGroups()) { if (sg.getColourScheme() != null) @@ -122,7 +122,7 @@ public class AnnotationColourChooser extends AnnotationRowFilter } Vector annotItems = getAnnotationItems( seqAssociated.isSelected()); - annotations = new JComboBox(annotItems); + annotations = new JComboBox<>(annotItems); populateThresholdComboBox(threshold); @@ -341,7 +341,7 @@ public class AnnotationColourChooser extends AnnotationRowFilter getCurrentAnnotation().threshold.value = slider.getValue() / 1000f; propagateSeqAssociatedThreshold(updateAllAnnotation, getCurrentAnnotation()); - ap.paintAlignment(false); + ap.paintAlignment(false, false); } } @@ -415,12 +415,9 @@ public class AnnotationColourChooser extends AnnotationRowFilter colorAlignmentContaining(getCurrentAnnotation(), selectedThresholdItem); ap.alignmentChanged(); - // ensure all associated views (overviews, structures, etc) are notified of - // updated colours. - ap.paintAlignment(true); } - protected boolean colorAlignmentContaining(AlignmentAnnotation currentAnn, + protected void colorAlignmentContaining(AlignmentAnnotation currentAnn, int selectedThresholdOption) { @@ -460,7 +457,13 @@ public class AnnotationColourChooser extends AnnotationRowFilter acg.getInstance(sg, ap.av.getHiddenRepSequences())); } } - return false; + } + + @Override + protected void sliderDragReleased() + { + super.sliderDragReleased(); + ap.paintAlignment(true, true); } }