diff options
author | Julian T <julian@jtle.dk> | 2022-03-14 18:50:46 +0100 |
---|---|---|
committer | Julian T <julian@jtle.dk> | 2022-03-14 18:50:46 +0100 |
commit | 535cda761c846195e0e0f36bed6ad5e77587e794 (patch) | |
tree | 8b33c3430f79dcec19a0d9aea4e980e9710be8b6 /intcp-mapper.nix | |
parent | 122fb9a33ec133070a4d0c9da34607b480e2a29e (diff) |
More keymapping and x230 things
Diffstat (limited to 'intcp-mapper.nix')
-rw-r--r-- | intcp-mapper.nix | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/intcp-mapper.nix b/intcp-mapper.nix index 5863f85..95f0a6a 100644 --- a/intcp-mapper.nix +++ b/intcp-mapper.nix @@ -20,11 +20,13 @@ int main(void) { */ if (event.type == EV_KEY) { + switch (event.code) { ${ lib.concatStrings (map (m: '' - if (event.code == ${m.from}) { + case ${m.from}: event.code = ${m.to}; - } + break; '') mappings) } + } } fwrite(&event, sizeof(event), 1, stdout); |