feature(keymaps): Keymap layer state event, highest layer API
* Fire an event w/ layer number, state, and timestamp when a layer is activated/deactivated. * Add `zmk_keymap_highest_layer_active()` query. Co-authored-by: KemoNine <mcrosson@kemonine.info>
This commit is contained in:
parent
4c92a4e50f
commit
2427a4ab33
5 changed files with 77 additions and 17 deletions
10
app/src/events/layer_state_changed.c
Normal file
10
app/src/events/layer_state_changed.c
Normal file
|
|
@ -0,0 +1,10 @@
|
|||
/*
|
||||
* Copyright (c) 2020 The ZMK Contributors
|
||||
*
|
||||
* SPDX-License-Identifier: MIT
|
||||
*/
|
||||
|
||||
#include <kernel.h>
|
||||
#include <zmk/events/layer-state-changed.h>
|
||||
|
||||
ZMK_EVENT_IMPL(layer_state_changed);
|
||||
Loading…
Add table
Add a link
Reference in a new issue