From: amwaterhouse Date: Mon, 11 Jul 2005 14:05:44 +0000 (+0000) Subject: check groupsize is non zero X-Git-Tag: Release_2_01~6 X-Git-Url: http://source.jalview.org/gitweb/?a=commitdiff_plain;h=187b75ac779575fa0399f7c3991dcd7bade8ca90;p=jalview.git check groupsize is non zero --- diff --git a/src/jalview/appletgui/AlignFrame.java b/src/jalview/appletgui/AlignFrame.java index 079a756..491d2be 100755 --- a/src/jalview/appletgui/AlignFrame.java +++ b/src/jalview/appletgui/AlignFrame.java @@ -567,7 +567,8 @@ public class AlignFrame int start=0, end = viewport.alignment.getWidth(); - if(viewport.getSelectionGroup()!=null) + if(viewport.getSelectionGroup()!=null + || viewport.getSelectionGroup().sequences.size()<1) { seqs = viewport.getSelectionGroup().sequences; start = viewport.getSelectionGroup().getStartRes(); diff --git a/src/jalview/gui/AlignFrame.java b/src/jalview/gui/AlignFrame.java index 2f7e5a8..9ce03f4 100755 --- a/src/jalview/gui/AlignFrame.java +++ b/src/jalview/gui/AlignFrame.java @@ -917,7 +917,8 @@ public class AlignFrame extends GAlignFrame int start = 0; int end = viewport.alignment.getWidth(); - if (viewport.getSelectionGroup() != null) + if (viewport.getSelectionGroup() != null + || viewport.getSelectionGroup().sequences.size()<1) { seqs = viewport.getSelectionGroup().sequences; start = viewport.getSelectionGroup().getStartRes(); diff --git a/src/jalview/gui/AlignViewport.java b/src/jalview/gui/AlignViewport.java index e8f34d8..3af97ab 100755 --- a/src/jalview/gui/AlignViewport.java +++ b/src/jalview/gui/AlignViewport.java @@ -58,7 +58,7 @@ public class AlignViewport ColourSchemeI globalColourScheme = null; boolean conservationColourSelected = false; boolean abovePIDThreshold = false; - SequenceGroup selectionGroup = new SequenceGroup(); + SequenceGroup selectionGroup; int charHeight; int charWidth; int chunkWidth;