From: BobHanson Date: Mon, 1 Jun 2020 21:43:44 +0000 (-0500) Subject: JAL-3262 from JAL-3253-applet JalviewApp integration X-Git-Url: http://source.jalview.org/gitweb/?a=commitdiff_plain;h=fa59a84ef77f47c75f11933ff03656eb0fc2ff14;p=jalview.git JAL-3262 from JAL-3253-applet JalviewApp integration --- diff --git a/src/jalview/gui/AlignFrame.java b/src/jalview/gui/AlignFrame.java index 89628e7..f719086 100644 --- a/src/jalview/gui/AlignFrame.java +++ b/src/jalview/gui/AlignFrame.java @@ -4862,6 +4862,33 @@ public class AlignFrame extends GAlignFrame implements DropTargetListener, } /** + * Change the display state for the given feature groups -- Added by BH from + * JalviewLite + * + * @param groups + * list of group strings + * @param state + * visible or invisible + */ + public void setFeatureGroupState(String[] groups, boolean state) + { + jalview.api.FeatureRenderer fr = null; + viewport.setShowSequenceFeatures(true); + if (alignPanel != null + && (fr = alignPanel.getFeatureRenderer()) != null) + { + + fr.setGroupVisibility(Arrays.asList(groups), state); + alignPanel.getSeqPanel().seqCanvas.repaint(); + if (alignPanel.overviewPanel != null) + { + alignPanel.overviewPanel.updateOverviewImage(); + } + } + } + + + /** * Method invoked by the ChangeListener on the tabbed pane, in other words * when a different tabbed pane is selected by the user or programmatically. */