aboutsummaryrefslogtreecommitdiff
path: root/tests/tap_dance
diff options
context:
space:
mode:
authorNick Brassel <[email protected]>2024-07-06 09:57:54 +1000
committerGitHub <[email protected]>2024-07-06 00:57:54 +0100
commit4ae0ca5a11c475ee49bbce13d29edbf9bd6fc636 (patch)
tree3db17c17257f9079a9dbf847041e4af255e89fbf /tests/tap_dance
parentb9e67347f1db160a5d1bd718ab0713a407014e43 (diff)
downloadqmk_firmware-4ae0ca5a11c475ee49bbce13d29edbf9bd6fc636.tar.gz
qmk_firmware-4ae0ca5a11c475ee49bbce13d29edbf9bd6fc636.zip
Tap dance introspection (#24049)
Diffstat (limited to 'tests/tap_dance')
-rw-r--r--tests/tap_dance/examples.c3
-rw-r--r--tests/tap_dance/tap_dance_layers/test.mk2
-rw-r--r--tests/tap_dance/test.mk3
3 files changed, 4 insertions, 4 deletions
diff --git a/tests/tap_dance/examples.c b/tests/tap_dance/examples.c
index 5377b397d3..4b6bdb2090 100644
--- a/tests/tap_dance/examples.c
+++ b/tests/tap_dance/examples.c
@@ -16,6 +16,7 @@
#include "quantum.h"
#include "examples.h"
+#include "keymap_introspection.h"
// Example code from the tap dance documentation, adapted for testing
@@ -83,7 +84,7 @@ bool process_record_user(uint16_t keycode, keyrecord_t *record) {
switch (keycode) {
case TD(CT_CLN):
- action = &tap_dance_actions[QK_TAP_DANCE_GET_INDEX(keycode)];
+ action = tap_dance_get(QK_TAP_DANCE_GET_INDEX(keycode));
if (!record->event.pressed && action->state.count && !action->state.finished) {
tap_dance_tap_hold_t *tap_hold = (tap_dance_tap_hold_t *)action->user_data;
tap_code16(tap_hold->tap);
diff --git a/tests/tap_dance/tap_dance_layers/test.mk b/tests/tap_dance/tap_dance_layers/test.mk
index b4cdc9b088..a677fda648 100644
--- a/tests/tap_dance/tap_dance_layers/test.mk
+++ b/tests/tap_dance/tap_dance_layers/test.mk
@@ -7,4 +7,4 @@
TAP_DANCE_ENABLE = yes
-SRC += tap_dance_defs.c
+INTROSPECTION_KEYMAP_C = tap_dance_defs.c
diff --git a/tests/tap_dance/test.mk b/tests/tap_dance/test.mk
index 041d9b4dc9..0e727da9e8 100644
--- a/tests/tap_dance/test.mk
+++ b/tests/tap_dance/test.mk
@@ -18,5 +18,4 @@
# --------------------------------------------------------------------------------
TAP_DANCE_ENABLE = yes
-
-SRC += examples.c
+INTROSPECTION_KEYMAP_C = examples.c