Jalview-JS/JAL-3253 applet params jpredfile, jnetfile
[jalview.git] / src / jalview / gui / AlignFrame.java
index 343dfbe..f2b790d 100644 (file)
@@ -4805,11 +4805,7 @@ public class AlignFrame extends GAlignFrame implements DropTargetListener,
       }
       if (isAnnotation)
       {
-
-        alignPanel.adjustAnnotationHeight();
-        viewport.updateSequenceIdColours();
-        buildSortByAnnotationScoresMenu();
-        alignPanel.paintAlignment(true, true);
+        updateForAnnotations();
       }
     } catch (Exception ex)
     {
@@ -4838,6 +4834,18 @@ public class AlignFrame extends GAlignFrame implements DropTargetListener,
   }
 
   /**
+   * Do all updates necessary after an annotation file such as jnet. Also called
+   * from Jalview.loadAppletParams for "annotations", "jnetFile"
+   */
+  public void updateForAnnotations()
+  {
+    alignPanel.adjustAnnotationHeight();
+    viewport.updateSequenceIdColours();
+    buildSortByAnnotationScoresMenu();
+    alignPanel.paintAlignment(true, true);
+  }
+
+  /**
    * Method invoked by the ChangeListener on the tabbed pane, in other words
    * when a different tabbed pane is selected by the user or programmatically.
    */