|
Evaluating "OSPlatform current keyForValue: 255" on a Linux machine returns: "Key Unknown code: (255)". 255 is the code for the left shift key. The problem appears to be that KeyboardKey class>>unixVirtualKeyTable uses the default KeyTable instead of the UnixKeyTable. Changing the method to return the proper key table, we can get the result of "Key SHIFT_L code: (65505)":
KeyboardKey class>>unixVirtualKeyTable UnixVirtualKeyTable ifNil: [ self initializeUnixVirtualKeyTable. ]. ^UnixVirtualKeyTable
Also, inside the KeyboardKey class>>initializeUnixVirtualKeyTable, the right control and right option keys aren't defined like they are in the VM sources (sqUnixX11.c). The current code is:
at: -1 put: (self value: 16rffea); " kVK_RightOption = 0x3D" at: -1 put: (self value: 16rffe4); " kVK_RightControl = 0x3E"
From the VM sources, the right option (alt) is value 246 and the right control is 250, so the code in that method should be:
at: 246 put: (self value: 16rffea); " kVK_RightOption = 0x3D" at: 250 put: (self value: 16rffe4); " kVK_RightControl = 0x3E"
This was tested in: Pharo 7.0.0 Build information: Pharo-7.0.0+rc1.build.36.sha.67dc1e8f9bae67bf17001a7c46413b072b19aa52 (64 Bit)
|
|
|
Priority: 4 – Would be nice
|
|
Status: Work Needed
|
|
Assigned to: Everyone
|
|
Milestone: Later
|
Go to Case
|
|