import jalview.schemes.AnnotationColourGradient;
import jalview.util.MessageManager;
+import java.awt.event.FocusAdapter;
+import java.awt.event.FocusEvent;
import java.awt.event.MouseAdapter;
import java.awt.event.MouseEvent;
import java.util.Vector;
{
this.av = av;
this.ap = ap;
+ thresholdValue.addFocusListener(new FocusAdapter()
+ {
+ @Override
+ public void focusLost(FocusEvent e)
+ {
+ thresholdValue_actionPerformed();
+ }
+ });
}
public AnnotationRowFilter()
}
}
- protected boolean colorAlignmContaining(
- AlignmentAnnotation currentAnn, int selectedThresholdOption)
+ protected boolean colorAlignmContaining(AlignmentAnnotation currentAnn,
+ int selectedThresholdOption)
{
AnnotationColourGradient acg = null;
}
acg.setSeqAssociated(seqAssociated.isSelected());
- if (currentAnn.graphMin == 0f
- && currentAnn.graphMax == 0f)
+ if (currentAnn.graphMin == 0f && currentAnn.graphMax == 0f)
{
acg.setPredefinedColours(true);
}
continue;
}
+ AnnotationColourGradient scheme = null;
if (currentColours.isSelected())
{
- sg.cs = new AnnotationColourGradient(currentAnn, sg.cs,
- selectedThresholdOption);
- ((AnnotationColourGradient) sg.cs).setSeqAssociated(seqAssociated
- .isSelected());
-
+ scheme = new AnnotationColourGradient(currentAnn,
+ sg.getColourScheme(), selectedThresholdOption);
}
else
{
- sg.cs = new AnnotationColourGradient(currentAnn,
+ scheme = new AnnotationColourGradient(currentAnn,
minColour.getBackground(), maxColour.getBackground(),
selectedThresholdOption);
- ((AnnotationColourGradient) sg.cs).setSeqAssociated(seqAssociated
- .isSelected());
}
-
+ scheme.setSeqAssociated(seqAssociated.isSelected());
+ sg.setColourScheme(scheme);
}
}
return false;