From: Jim Procter Date: Fri, 9 Nov 2018 15:01:54 +0000 (+0000) Subject: JAL-3127 polished setColor after review X-Git-Tag: Release_2_11_0~17^2~46^2~9 X-Git-Url: http://source.jalview.org/gitweb/?a=commitdiff_plain;h=56a02618a557711eed7879f72ac916ffb40c0a3f;p=jalview.git JAL-3127 polished setColor after review --- diff --git a/src/jalview/gui/TreeCanvas.java b/src/jalview/gui/TreeCanvas.java index 85ee4bf..67ddbd1 100755 --- a/src/jalview/gui/TreeCanvas.java +++ b/src/jalview/gui/TreeCanvas.java @@ -514,21 +514,18 @@ public class TreeCanvas extends JPanel implements MouseListener, Runnable, node.color = c; if (node.element() instanceof SequenceI) { + final SequenceI seq = (SequenceI) node.element(); AlignmentPanel[] aps = getAssociatedPanels(); if (aps != null) { for (int a = 0; a < aps.length; a++) { - final SequenceI seq = (SequenceI) node.element(); aps[a].av.setSequenceColour(seq, c); } } } - if ((node.left() != null) || (node.right() != null)) // TODO: internal node - { - setColor((SequenceNode) node.left(), c); - setColor((SequenceNode) node.right(), c); - } + setColor((SequenceNode) node.left(), c); + setColor((SequenceNode) node.right(), c); } /**