ru.biosoft.graphics.editor
Class InsertAction
java.lang.Object
|
+--javax.swing.AbstractAction
|
+--ru.biosoft.graphics.editor.InsertAction
- public class InsertAction
- extends AbstractAction
The InsertAction class extends functionality of AbstractAction.
| Field Summary |
final static String | TYPE Type of element to be created and inserted during this action processing. |
| Constructor Summary |
InsertAction() Dummy constructor. |
InsertAction(Class type, String name, String shortDesc, String longDesc, int mnemonic, String imageFile, ActionListener listener) Defines an Action object with the specified
type of element to be inserted, and action name, long/short description string,
mnemonic key, icon and action listener. |
InsertAction(Class type, Icon icon) Creates InsertAction for the specified type. |
| Method Summary |
void | actionPerformed(ActionEvent evt) Overridden method for translation action events to the all listeners |
void | addActionListener(ActionListener l) Adds the specified action listener to receive action event . |
static Icon | getIcon(String imageFile) Initialise icon from the specified image file. |
void | removeActionListeners(Class clazz) |
| Methods inherited from class javax.swing.AbstractAction |
getValue, putValue, isEnabled, setEnabled, getKeys, addPropertyChangeListener, removePropertyChangeListener |
| Methods inherited from class java.lang.Object |
getClass, hashCode, equals, toString, notify, notifyAll, wait, wait, wait |
TYPE
public final static String TYPE
- Type of element to be created and inserted during this action processing.
InsertAction
public InsertAction()
- Dummy constructor. It is suggessted that action will be initialised using ActionInitialiser.
InsertAction
public InsertAction(Class type, String name, String shortDesc, String longDesc, int mnemonic, String imageFile, ActionListener listener)
- Defines an
Action object with the specified
type of element to be inserted, and action name, long/short description string,
mnemonic key, icon and action listener.- Parameters:
- type - type of element to be created and inserted when this action is processed
- name - name of action
- shortDesc - shortDesc short description of action
- longDesc - longDesc long description of action
- mnemonic - mnemonic hot key
- imageFile - image for icon on button or menu items
- listener - listener listener of action
InsertAction
public InsertAction(Class type, Icon icon)
- Creates InsertAction for the specified type.
Information for name and short descriptions are extracted from type BeanInfo.
- Parameters:
- type - type of element to be created and inserted during the action processing.
- icon - - iacon for this action
actionPerformed
public void actionPerformed(ActionEvent evt)
- Overridden method for translation action events to the all listeners
- Parameters:
- evt - ActionEvent
addActionListener
public void addActionListener(ActionListener l)
- Adds the specified action listener to receive action event .
getIcon
public static Icon getIcon(String imageFile)
- Initialise icon from the specified image file.
removeActionListeners
public void removeActionListeners(Class clazz)
to Class org.apache.log4j.Category
to Class java.lang.String
- Type of element to be created and inserted during this action processing.
to Class java.util.Vector
- Action listener
BOTTOM