JAL-2431 show cDNA consensus after New View in split frame
[jalview.git] / src / jalview / viewmodel / AlignmentViewport.java
index 0c470fe..6dcf26d 100644 (file)
@@ -1898,10 +1898,10 @@ public abstract class AlignmentViewport implements AlignViewportI,
   }
 
   /**
-   * If this is a protein alignment and there are mappings to cDNA, add the cDNA
-   * consensus annotation.
+   * If this is a protein alignment and there are mappings to cDNA, adds the
+   * cDNA consensus annotation and returns true, else returns false.
    */
-  public void initComplementConsensus()
+  public boolean initComplementConsensus()
   {
     if (!alignment.isNucleotide())
     {
@@ -1928,9 +1928,11 @@ public abstract class AlignmentViewport implements AlignViewportI,
                   "PID for cDNA", new Annotation[1], 0f, 100f,
                   AlignmentAnnotation.BAR_GRAPH);
           initConsensus(complementConsensus);
+          return true;
         }
       }
     }
+    return false;
   }
 
   private void initConsensus(AlignmentAnnotation aa)