minor bug removed
authorcmzmasek@gmail.com <cmzmasek@gmail.com@ca865154-3058-d1c3-3e42-d8f55a55bdbd>
Thu, 26 Sep 2013 00:00:49 +0000 (00:00 +0000)
committercmzmasek@gmail.com <cmzmasek@gmail.com@ca865154-3058-d1c3-3e42-d8f55a55bdbd>
Thu, 26 Sep 2013 00:00:49 +0000 (00:00 +0000)
forester/java/src/org/forester/archaeopteryx/ControlPanel.java

index eab1ea8..656cb75 100644 (file)
@@ -433,9 +433,15 @@ final class ControlPanel extends JPanel implements ActionListener {
     }
 
     void showAnnotations() {
-        _show_annotation.setSelected( true );
-        _color_according_to_annotation.setSelected( true );
-        _color_acc_species.setSelected( false );
+        if ( _show_annotation != null ) {
+            _show_annotation.setSelected( true );
+        }
+        if ( _color_according_to_annotation != null ) {
+            _color_according_to_annotation.setSelected( true );
+        }
+        if ( _color_acc_species != null ) {
+            _color_acc_species.setSelected( false );
+        }
         _mainpanel.getCurrentTreePanel().repaint();
     }