Null pointers removed
authoramwaterhouse <Andrew Waterhouse>
Mon, 12 Sep 2005 16:56:12 +0000 (16:56 +0000)
committeramwaterhouse <Andrew Waterhouse>
Mon, 12 Sep 2005 16:56:12 +0000 (16:56 +0000)
src/jalview/gui/AnnotationPanel.java

index aeb0b9a..f13bc91 100755 (executable)
@@ -148,7 +148,7 @@ public class AnnotationPanel extends JPanel implements MouseListener,
         if (activeRow == -1)\r
         {\r
             AlignmentAnnotation[] aa = av.alignment.getAlignmentAnnotation();\r
-\r
+            if(aa!=null)\r
             for (int j = 0; j < aa.length; j++)\r
             {\r
                 if (aa[j].editable)\r
@@ -178,6 +178,8 @@ public class AnnotationPanel extends JPanel implements MouseListener,
         if (activeRow == -1)\r
         {\r
             AlignmentAnnotation[] aa = av.alignment.getAlignmentAnnotation();\r
+            if(aa==null)\r
+              return;\r
 \r
             for (int j = 0; j < aa.length; j++)\r
             {\r