Make the right shift key work in OemToAscii (only the left shift key was working)

This commit is contained in:
David Kemp 2014-10-23 21:51:48 +11:00
parent 58a143b9fb
commit 8222d047f5

View file

@ -189,8 +189,8 @@ uint8_t KeyboardReportParser::OemToAscii(uint8_t mod, uint8_t key) {
// [a-z]
if (VALUE_WITHIN(key, 0x04, 0x1d)) {
// Upper case letters
if ((kbdLockingKeys.kbdLeds.bmCapsLock == 0 && (mod & 2)) ||
(kbdLockingKeys.kbdLeds.bmCapsLock == 1 && (mod & 2) == 0))
if ((kbdLockingKeys.kbdLeds.bmCapsLock == 0 && shift) ||
(kbdLockingKeys.kbdLeds.bmCapsLock == 1 && shift == 0))
return (key - 4 + 'A');
// Lower case letters