United StatesChange Country, Oracle Worldwide Web Sites Communities I am a... I want to...
Bug ID: JDK-6678061 undefined keycodes for certain keyboard layouts
JDK-6678061 : undefined keycodes for certain keyboard layouts

Details
Type:
Bug
Submit Date:
2008-03-20
Status:
Resolved
Updated Date:
2010-12-09
Project Name:
JDK
Resolved Date:
2008-06-17
Component:
client-libs
OS:
windows
Sub-Component:
java.awt
CPU:
x86
Priority:
P2
Resolution:
Fixed
Affected Versions:
5.0u14
Fixed Versions:
5.0u16-rev (b03)

Related Reports
Backport:
Backport:
Relates:

Sub Tasks

Description
This is IBIS case 70131512.

Apparently in customer's lab testing everything went well, but in the field 
they have found some keyCodes that don't match to unique raw codes.

Below is a snapshot of the results of pressing three different keys on
the system.

Windows :
KeyCode = 255 , ScanCode = 112
KeyCode = 255 , ScanCode = 125 (F14)
KeyCode = 255 , ScanCode = 114


Sun Java
KeyCode = 0 , Rawcode = 255
KeyCode = 0 , RawCode = 255 
KeyCode = 0 , RawCode = 255

As we can see based on the above there is no way to distinguish the
three keys in the SunJVM. 

The keys won't be found on a regular US 101 keyboard.
These are keys found on customer's 160 key Access keyboard.
However customer's point to Sun when they designed this rawcode workaround was
that regardless of keycode as there may be several that may be undefined
based on layout as long as there is a unique scancode passed by the OS it shouldbe uniquely represented in the JVM.
escalated to sustaining IBIS task 80137307

                                    

Comments
EVALUATION

For MS Windows, it may be sufficient to pass all the way up a scancode just like we do with (Windows) virtual keycode. Unfortunately, this will hardly work for X Window.
                                     
2008-03-27



Hardware and Software, Engineered to Work Together