diff options
author | Daniel Shields <daniel.shields@bcs.org> | 2019-09-21 19:04:27 +0100 |
---|---|---|
committer | Drashna Jaelre <drashna@live.com> | 2019-09-21 11:04:27 -0700 |
commit | 63a0b1241d204873cd5156a959e913c602b0c386 (patch) | |
tree | 69ec7c084ed0ef26c50e23017ec32a3e483de679 /users/dshields/dshields.c | |
parent | 75c97477874b9354a90b8b4eca2d3b1ecfc15435 (diff) |
[Keymap] Move common code and configuration to userspace for dshields keymaps. (#6537)
Diffstat (limited to 'users/dshields/dshields.c')
-rw-r--r-- | users/dshields/dshields.c | 30 |
1 files changed, 30 insertions, 0 deletions
diff --git a/users/dshields/dshields.c b/users/dshields/dshields.c new file mode 100644 index 0000000000..6aff5c6716 --- /dev/null +++ b/users/dshields/dshields.c @@ -0,0 +1,30 @@ +extern keymap_config_t keymap_config; + +/* uncomment to reset +void matrix_init_user(void) { + eeconfig_init(); +}; +*/ + +bool process_record_user(uint16_t keycode, keyrecord_t *record) { + if (!process_record_dynamic_macro(keycode, record)) { + return false; + } + return true; +} + +// work in progress +uint32_t layer_state_set_user(uint32_t state) { + switch (biton32(state)) { + case DEF: + set_all_leds_to(0,0,0); + break; + case FUN: + // TODO light the fn keys + // set_led_to(?, 0, 128, 0); + // set_led_to(?, 0, 128, 0); + break; + } + return state; +} + |