import jalview.bin.Cache;
import jalview.datamodel.AlignmentAnnotation;
+import jalview.datamodel.GraphLine;
import jalview.datamodel.SequenceGroup;
import jalview.schemes.AnnotationColourGradient;
import jalview.schemes.ColourSchemeI;
for (int i = 0; i < av.getAlignment().getAlignmentAnnotation().length; i++)
{
AlignmentAnnotation aa = av.getAlignment().getAlignmentAnnotation()[i];
- if (aa.label.equals(currentAnnotation.label))
+ if (aa.label.equals(currentAnnotation.label)
+ && (currentAnnotation.getCalcId() == null ? aa.getCalcId() == null
+ : currentAnnotation.getCalcId()
+ .equals(aa.getCalcId())))
{
- aa.threshold.value = thr;
+ if (aa.threshold == null)
+ {
+ aa.threshold = new GraphLine(currentAnnotation.threshold);
+ }
+ else
+ {
+ aa.threshold.value = thr;
+ }
}
}
}