public void addConfigurationAction( String category, ConfigurationAction<?> action, Activator activator) { JCheckBoxMenuItem item = MenuBar.makeMenuItem(action.getValue(Action.NAME).toString(), JCheckBoxMenuItem.class); menuBar.addItem(category, item); item.setToolTipText(action.getValue(Action.SHORT_DESCRIPTION).toString()); item.setIcon((Icon) action.getValue(Action.SMALL_ICON)); if (activator != null) { registerComponent(item, activator); } item.addActionListener(action); enableComponents.registerConfigurationAction(action, item); }
void enableComponents() { enableComponents.enableComponents(); }
void registerComponent(JComponent comp, Activator activator) { enableComponents.registerButton(comp, activator); }