From: amwaterhouse Date: Tue, 14 Dec 2004 14:51:55 +0000 (+0000) Subject: Increment panel must call globalcolour or seqeuncegroup colour X-Git-Tag: Release_2_0~828 X-Git-Url: http://source.jalview.org/gitweb/?a=commitdiff_plain;h=bcc6d64b37d802973ab2168374fc1df0884cc9ab;p=jalview.git Increment panel must call globalcolour or seqeuncegroup colour --- diff --git a/src/jalview/gui/ConservationIncrementPanel.java b/src/jalview/gui/ConservationIncrementPanel.java index 7f8fc6b..92c35f5 100755 --- a/src/jalview/gui/ConservationIncrementPanel.java +++ b/src/jalview/gui/ConservationIncrementPanel.java @@ -32,23 +32,20 @@ public class ConservationIncrementPanel extends GConservationIncrementPanel { java.util.Vector groups = av.getAlignment().getGroups(); - if(av.getSelection().size()==0) - { - // change increment for all - for (int j = 0; j < groups.size(); j++) - { - SequenceGroup sg = ( (SequenceGroup) groups.elementAt(j)); - if (sg.cs instanceof ConservationColourScheme) - ( (ConservationColourScheme) sg.cs).inc = i; - } - } - else + + for (int j = 0; j < groups.size(); j++) { - SequenceGroup sg = av.alignment.findGroup( (Sequence) av.sel.sequenceAt(0)); - if (sg.cs instanceof ConservationColourScheme) - ( (ConservationColourScheme) sg.cs).inc = i; + SequenceGroup sg = ( (SequenceGroup) groups.elementAt(j)); + if (sg.cs instanceof ConservationColourScheme) + ( (ConservationColourScheme) sg.cs).inc = i; } + + + if (av.getGlobalColourScheme() instanceof ConservationColourScheme) + ( (ConservationColourScheme) av.getGlobalColourScheme()).inc = i; + + ap.seqPanel.seqCanvas.paintFlag=true; ap.seqPanel.repaint();