From: hansonr Date: Thu, 18 Apr 2019 17:59:40 +0000 (-0500) Subject: // BH 2018.04.18 comment: addNotify() is not appropriate here. We X-Git-Tag: Release_2_11_4_0~45^2~18^2~140 X-Git-Url: http://source.jalview.org/gitweb/?a=commitdiff_plain;h=6253934041436194fa73dd6af26d534247cea6de;p=jalview.git // BH 2018.04.18 comment: addNotify() is not appropriate here. We // are not changing ancestors, and keyboard action listeners do // not need to be reset. addNotify() is a very expensive operation, // requiring a full re-layout of all parents and children. // Note in JComponent: // This method is called by the toolkit internally and should // not be called directly by programs. // I note that addNotify() is called in several areas of Jalview. --- diff --git a/src/jalview/gui/AlignmentPanel.java b/src/jalview/gui/AlignmentPanel.java index 20f8cd1..9cb690f 100644 --- a/src/jalview/gui/AlignmentPanel.java +++ b/src/jalview/gui/AlignmentPanel.java @@ -550,6 +550,7 @@ public class AlignmentPanel extends GAlignmentPanel implements // Note in JComponent: // This method is called by the toolkit internally and should // not be called directly by programs. + // I note that addNotify() is called in several areas of Jalview. int annotationHeight = getAnnotationPanel().adjustPanelHeight(); annotationHeight = getAnnotationPanel()