From 3be19c1e81d0960f7e7f03e600abdc912890c761 Mon Sep 17 00:00:00 2001 From: gmungoc Date: Thu, 4 Feb 2016 14:02:16 +0000 Subject: [PATCH] JAL-599 bug fixed so array of visible types is populated --- src/jalview/controller/AlignViewController.java | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) diff --git a/src/jalview/controller/AlignViewController.java b/src/jalview/controller/AlignViewController.java index 06b1e4c..6a7e222 100644 --- a/src/jalview/controller/AlignViewController.java +++ b/src/jalview/controller/AlignViewController.java @@ -333,20 +333,20 @@ public class AlignViewController implements AlignViewControllerI gps = fr == null ? null : fr.getDisplayedFeatureGroups(); if (typ != null) { - ArrayList types = new ArrayList(); - for (int i = 0; i < typ.length; i++) + List types = new ArrayList(); + for (String displayed : typ) { - if (typ[i] != null) + if (displayed != null) { - types.add(typ[i]); + types.add(displayed); } - typ = new String[types.size()]; - types.toArray(typ); } + typ = new String[types.size()]; + types.toArray(typ); } if (gps != null) { - ArrayList grps = new ArrayList(); + List grps = new ArrayList(); for (int i = 0; i < gps.length; i++) { -- 1.7.10.2