JAL-2001 use fast column selection test
authorJim Procter <jprocter@issues.jalview.org>
Mon, 4 Apr 2016 14:23:52 +0000 (15:23 +0100)
committerJim Procter <jprocter@issues.jalview.org>
Mon, 4 Apr 2016 14:23:52 +0000 (15:23 +0100)
src/jalview/renderer/AnnotationRenderer.java

index 007df3e..2d84289 100644 (file)
@@ -598,12 +598,9 @@ public class AnnotationRenderer
 
               if (columnSelection != null)
               {
-                for (int v : columnSelection.getSelected())
+                if (columnSelection.isSelected(column))
                 {
-                  if (v == column)
-                  {
-                    g.fillRect(x * charWidth, y, charWidth, charHeight);
-                  }
+                  g.fillRect(x * charWidth, y, charWidth, charHeight);
                 }
               }
             }