Merge branch 'bug/JAL-98consensusMemory' into develop
authorgmungoc <g.m.carstairs@dundee.ac.uk>
Wed, 26 Oct 2016 15:22:45 +0000 (16:22 +0100)
committergmungoc <g.m.carstairs@dundee.ac.uk>
Wed, 26 Oct 2016 15:22:45 +0000 (16:22 +0100)
1  2 
src/jalview/viewmodel/AlignmentViewport.java

@@@ -22,6 -22,7 +22,7 @@@ package jalview.viewmodel
  
  import jalview.analysis.AnnotationSorter.SequenceAnnotationOrder;
  import jalview.analysis.Conservation;
+ import jalview.analysis.Profile;
  import jalview.api.AlignCalcManagerI;
  import jalview.api.AlignViewportI;
  import jalview.api.AlignmentViewPanel;
@@@ -612,7 -613,7 +613,7 @@@ public abstract class AlignmentViewpor
      boolean recalc = false;
      if (cs != null)
      {
 -      cs.setConservationApplied(recalc = getConservationSelected());
 +      recalc = getConservationSelected();
        if (getAbovePIDThreshold() || cs instanceof PIDColourScheme
                || cs instanceof Blosum62ColourScheme)
        {
          cs.setConsensus(hconsensus);
          cs.setConservation(hconservation);
        }
 +      cs.setConservationApplied(getConservationSelected());
        cs.alignmentChanged(alignment, hiddenRepSequences);
      }
      if (getColourAppliesToAllGroups())
    /**
     * results of alignment consensus analysis for visible portion of view
     */
-   protected Hashtable[] hconsensus = null;
+   protected Profile[] hconsensus = null;
  
    /**
     * results of cDNA complement consensus visible portion of view
    }
  
    @Override
-   public void setSequenceConsensusHash(Hashtable[] hconsensus)
+   public void setSequenceConsensusHash(Profile[] hconsensus)
    {
      this.hconsensus = hconsensus;
    }
    }
  
    @Override
-   public Hashtable[] getSequenceConsensusHash()
+   public Profile[] getSequenceConsensusHash()
    {
      return hconsensus;
    }
      groupConservation = null;
      hconsensus = null;
      hcomplementConsensus = null;
-     // TODO removed listeners from changeSupport?
+     // colour scheme may hold reference to consensus
+     globalColourScheme = null;
+     // TODO remove listeners from changeSupport?
      changeSupport = null;
      setAlignment(null);
    }