Name: mf23781 Date: 01/07/98
The virtual key for right Alt which is ALTGr on PC keyboards, needs
to be defined in KeyEvent. We would like to use the following define
for this key
VK_ALT_GRAPH = 0xFF;
The AWInputEventHandler.java class currently has hard code 0xFF for
this virtual key. The keyevent class should be updated with this virtual
key value so the master list of virtual keys doesn't used the 0xff for
another virtual key.
src\share\sun\sun\awt\aw\AWInputEventHandler.java
/**
*
*/
public void handleKeyEvent(
JOSKeyEvent keyEvent ) {
int keyCode = keyEvent.getKeyCode();
int id = keyEvent.getID();
if ( inputEventTest != null ) {
inputEventTest.handleKeyEvent( keyEvent );
return;
}
switch ( id ) {
case KeyEvent.KEY_PRESSED:
if ( keyCode == KeyEvent.VK_CAPS_LOCK )
isCapsLock = true;
else if ( keyCode == KeyEvent.VK_NUM_LOCK )
isNumLock = true;
else if (keyCode == KeyEvent.VK_KANA) {
// VK_KANA key should be handled as kana lock key
isModeSwitch = !isModeSwitch;
} else if (keyCode == 0xFF) { // Alt_Graph
isAltGraph = true;
}
break;
case KeyEvent.KEY_RELEASED:
if ( keyCode == KeyEvent.VK_CAPS_LOCK )
isCapsLock = false;
else if ( keyCode == KeyEvent.VK_NUM_LOCK ) {
isNumLock = false;
} else if (keyCode == 0xFF) { // Alt_Graph
isAltGraph = false;
}
break;
}
======================================================================