All Packages Class Hierarchy This Package Previous Next Index
Class CH.ifa.draw.util.CommandMenu
java.lang.Object
|
+----java.awt.MenuComponent
|
+----java.awt.MenuItem
|
+----java.awt.Menu
|
+----CH.ifa.draw.util.CommandMenu
- public class CommandMenu
- extends Menu
- implements ActionListener
-
CommandMenu(String)
-
-
actionPerformed(ActionEvent)
- Executes the command.
-
add(Command)
- Adds a command to the menu.
-
add(Command, MenuShortcut)
- Adds a command with the given short cut to the menu.
-
checkEnabled()
-
-
enable(String, boolean)
- Changes the enabling/disabling state of a named menu item.
-
remove(Command)
-
-
remove(MenuItem)
-
CommandMenu
public CommandMenu(String name)
add
public synchronized void add(Command command)
- Adds a command to the menu. The item's label is
the command's name.
add
public synchronized void add(Command command,
MenuShortcut shortcut)
- Adds a command with the given short cut to the menu. The item's label is
the command's name.
remove
public synchronized void remove(Command command)
remove
public synchronized void remove(MenuItem item)
enable
public synchronized void enable(String name,
boolean state)
- Changes the enabling/disabling state of a named menu item.
checkEnabled
public synchronized void checkEnabled()
actionPerformed
public void actionPerformed(ActionEvent e)
- Executes the command.
All Packages Class Hierarchy This Package Previous Next Index