mirror of
https://github.com/debauchee/barrier.git
synced 2025-06-17 10:11:40 +02:00
Fix for Bug #57. The event tap was never returning events of either of the types specified and so mapKeyFromEvent would prematurely return with a null-equivalent KeyButton. Pulling the entire block of code, as the value it produces isn't used anyway.
Also fixed an incorrect pair of constants in the event tap generation code. Luckily, the two constants resolve to the same integer value, but things would get ugly if either value changed. Thanks to Peter Van der Beken (peterv@propagandism.org) for the patch.
This commit is contained in:
parent
d4e3ead60a
commit
71e53f05c9
2 changed files with 2 additions and 18 deletions
|
@ -284,22 +284,6 @@ COSXKeyState::mapKeyFromEvent(CKeyIDs& ids,
|
|||
#endif
|
||||
|
||||
if (layoutValid) {
|
||||
|
||||
// choose action
|
||||
UInt16 action;
|
||||
switch (eventKind) {
|
||||
case kEventRawKeyDown:
|
||||
action = kUCKeyActionDown;
|
||||
break;
|
||||
|
||||
case kEventRawKeyRepeat:
|
||||
action = kUCKeyActionAutoKey;
|
||||
break;
|
||||
|
||||
default:
|
||||
return 0;
|
||||
}
|
||||
|
||||
// translate key
|
||||
UniCharCount count;
|
||||
UniChar chars[2];
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue