Merge pull request #98 from davidbkemp/master

Make the right shift key work in OemToAscii (only the left shift key was...
This commit is contained in:
Kristian Sloth Lauszus 2015-03-03 18:31:15 +01:00
commit 13851a466f

View file

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