List of utility methods to do JCheckBoxMenuItem
void | configureJCheckBoxMenuItem(final JCheckBoxMenuItem mi, final Action a) Configures a JCheckBoxMenuItem for an Action. mi.setAction(a); |
JMenuItem | createCheckBoxMenuItem(final JInternalFrame f) create Check Box Menu Item final JMenuItem theItem = new JCheckBoxMenuItem(f.getTitle()); theItem.addActionListener(new ActionListener() { public void actionPerformed(ActionEvent e) { try { f.setSelected(true); f.setIcon(false); } catch (PropertyVetoException exc) { ; ... |
JCheckBoxMenuItem | createCheckBoxMenuItem(final String text, final boolean selected) create Check Box Menu Item return new JCheckBoxMenuItem(text, selected); |
JCheckBoxMenuItem | createCheckBoxMenuItem(String label, int mnemonic, String description, ItemListener action) create Check Box Menu Item return createMenuItem(new JCheckBoxMenuItem(label), mnemonic, description, action); |
JCheckBoxMenuItem | createCheckBoxMenuItem(String text, Icon icon, String toolTip, ActionListener... listeners) create Check Box Menu Item JCheckBoxMenuItem result = new JCheckBoxMenuItem(text, icon); if (toolTip != null) { result.setToolTipText(toolTip); for (ActionListener listener : listeners) { result.addActionListener(listener); return result; ... |
JCheckBoxMenuItem | createJCheckBoxMenuItem(String name, String command, ActionListener listener, boolean isSelected) Creates a check box menu item with specified name, acton command and state. JCheckBoxMenuItem item = new JCheckBoxMenuItem(name); item.setActionCommand(command); item.addActionListener(listener); item.setSelected(isSelected); return item; |
void | unconfigureJCheckBoxMenuItem(JCheckBoxMenuItem mi, Action a) Unconfigures a JCheckBoxMenuItem for an Action. mi.setAction(null); |