From 4784282ef9a4d73781b601cde19455285e27c1a4 Mon Sep 17 00:00:00 2001 From: jprocter Date: Thu, 29 Apr 2010 16:09:07 +0000 Subject: [PATCH] make sure references are intact when group annotation is accessed --- src/jalview/datamodel/SequenceGroup.java | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/src/jalview/datamodel/SequenceGroup.java b/src/jalview/datamodel/SequenceGroup.java index fbcf303..dcb0150 100755 --- a/src/jalview/datamodel/SequenceGroup.java +++ b/src/jalview/datamodel/SequenceGroup.java @@ -953,10 +953,10 @@ public class SequenceGroup { consensus = new AlignmentAnnotation("","", new Annotation[1], 0f, 100f, AlignmentAnnotation.BAR_GRAPH); - consensus.hasText = true; - consensus.autoCalculated = true; - consensus.groupRef = this; } + consensus.hasText = true; + consensus.autoCalculated = true; + consensus.groupRef = this; consensus.label = "Consensus for "+getName(); consensus.description = "Percent Identity"; return consensus; @@ -969,10 +969,11 @@ public class SequenceGroup if (conservation == null) { conservation = new AlignmentAnnotation("","", new Annotation[1], 0f, 11f, AlignmentAnnotation.BAR_GRAPH); + } + conservation.hasText = true; conservation.autoCalculated = true; conservation.groupRef = this; - } conservation.label = "Conservation for "+getName(); conservation.description = "Conservation for group "+getName()+" less than " + consPercGaps + "% gaps"; -- 1.7.10.2