I have a Java Swing app in Which I have been able to set shortcut keys using the following piece of code. For example Ctrl+K.
keyHelp.setAccelerator(KeyStroke.getKeyStroke(KeyEvent.VK_K, Event.CTRL_MASK));
keyHelp.setMnemonic((int) 'K');//This is the Line I need Help in
I just can't figure out how to add the same using F1 key as the shortcut... Could anyone please help?