- annotationPanelMenuItem.setState(jalview.bin.Cache.getDefault(
- "SHOW_ANNOTATIONS", true));
- annotationPanelMenuItem
- .addActionListener(new java.awt.event.ActionListener()
- {
- @Override
- public void actionPerformed(ActionEvent e)
- {
- annotationPanelMenuItem_actionPerformed(e);
- }
- });
+ annotationPanelMenuItem.setState(Cache.getDefault("SHOW_ANNOTATIONS",
+ true));
+ annotationPanelMenuItem.addActionListener(new ActionListener()
+ {
+ @Override
+ public void actionPerformed(ActionEvent e)
+ {
+ annotationPanelMenuItem_actionPerformed(e);
+ }
+ });
+ /*
+ * Show/hide all annotations only enabled if annotation panel is shown
+ */
+ showAllAnnotations.setText(MessageManager
+ .getString("label.show_all_annotations"));
+ showAllAnnotations.setEnabled(annotationPanelMenuItem.getState());
+ showAllAnnotations.addActionListener(new ActionListener()
+ {
+ @Override
+ public void actionPerformed(ActionEvent e)
+ {
+ showAllAnnotations_actionPerformed();
+ }
+ });
+ hideAllAnnotations.setText(MessageManager
+ .getString("label.hide_all_annotations"));
+ hideAllAnnotations.setEnabled(annotationPanelMenuItem.getState());
+ hideAllAnnotations.addActionListener(new ActionListener()
+ {
+ @Override
+ public void actionPerformed(ActionEvent e)
+ {
+ hideAllAnnotations_actionPerformed();
+ }
+ });