ExitAction
From: - (nobody_at_hoem.com)
Date: 02/24/05
- Previous message: -: "public JMenu add(JMenu c)"
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
Date: Thu, 24 Feb 2005 10:29:08 +0800
i have the following class:
public class ExitAction extends AbstractAction {
public ExitAction() {
putValue(Action.NAME, "Exit);
putValue(Action.ACCELERATOR_KEY,
KeyStroke.getKeyStroke(KeyEvent.VK_F4,
ActionEvent.ALT_MASK));
putValue(Action.MNEMONIC_KEY, KeyEvent.VK_X);
....
....
}
public void actionPerformed(ActionEvent evt) {
....
....
}
}
is it better this way or is it redundant? should i just create a new
Action with these values rather than create a new ExitAction?
- Previous message: -: "public JMenu add(JMenu c)"
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]