mirror of
https://gitlab.com/interception/linux/plugins/caps2esc.git
synced 2025-05-21 01:22:24 +00:00
Discard MSC_SCAN events
Given that only EV_KEY events are being mapped, without their scancode counterparts, we just drop all scancode events to avoid having to map them too, to syncing it with the corresponding mapped keys. This is expected to be harmless.
This commit is contained in:
@ -39,6 +39,9 @@ int main(void) {
|
||||
setbuf(stdin, NULL), setbuf(stdout, NULL);
|
||||
|
||||
while (read_event(&input)) {
|
||||
if (input.type == EV_MSC && input.code == MSC_SCAN)
|
||||
continue;
|
||||
|
||||
if (input.type != EV_KEY) {
|
||||
write_event(&input);
|
||||
continue;
|
||||
|
Reference in New Issue
Block a user