1 36 37 import javax.swing.Action ; 38 39 42 public class HelpAction extends JLFAbstractAction { 43 44 private static final String ACTION_COMMAND_KEY_ABOUT = "help-command"; 45 private static final String NAME_ABOUT = "Help..."; 46 private static final String SMALL_ICON_ABOUT = "Help16.gif"; 47 private static final String LARGE_ICON_ABOUT = "Help24.gif";; 48 private static final String SHORT_DESCRIPTION_ABOUT = "Online help"; 49 private static final String LONG_DESCRIPTION_ABOUT = "Opens the online help system"; 50 private static final int MNEMONIC_KEY_ABOUT = 'H'; 51 52 public HelpAction() { 53 putValue(Action.NAME, NAME_ABOUT); 54 putValue(Action.SMALL_ICON, getIcon(SMALL_ICON_ABOUT)); 55 putValue(LARGE_ICON, getIcon(LARGE_ICON_ABOUT)); 56 putValue(Action.SHORT_DESCRIPTION, SHORT_DESCRIPTION_ABOUT); 57 putValue(Action.LONG_DESCRIPTION, LONG_DESCRIPTION_ABOUT); 58 putValue(Action.MNEMONIC_KEY, new Integer (MNEMONIC_KEY_ABOUT)); 59 putValue(Action.ACTION_COMMAND_KEY, ACTION_COMMAND_KEY_ABOUT); 60 } 61 62 } 63 | Popular Tags |