summaryrefslogtreecommitdiffstats
path: root/tmk_core/common/action.c
diff options
context:
space:
mode:
authorAlex Ong <the.onga@gmail.com>2019-01-26 02:13:19 +0100
committerAlex Ong <the.onga@gmail.com>2019-01-26 02:13:19 +0100
commitc9ba618654417ec115809a031d315f8327c79ad4 (patch)
treecd5b907af5bebde7062897ff847e473232ed1214 /tmk_core/common/action.c
parent2bb2977c133646c4e056960e72029270d77cc1eb (diff)
parentd977daa8dc9136746425f9e1414e1f93cb161877 (diff)
downloadqmk_firmware-c9ba618654417ec115809a031d315f8327c79ad4.tar.gz
qmk_firmware-c9ba618654417ec115809a031d315f8327c79ad4.tar.xz
DO NOT USE Merge branch 'master' into debounce_refactor
Merged, however now there are two debounce.h and debounce.c to mess around with and coalesce. # Conflicts: # quantum/matrix.c
Diffstat (limited to 'tmk_core/common/action.c')
-rw-r--r--tmk_core/common/action.c10
1 files changed, 9 insertions, 1 deletions
diff --git a/tmk_core/common/action.c b/tmk_core/common/action.c
index b99c2acaa..ec8d6ed7b 100644
--- a/tmk_core/common/action.c
+++ b/tmk_core/common/action.c
@@ -653,7 +653,7 @@ void process_action(keyrecord_t *record, action_t action)
#ifndef NO_ACTION_TAPPING
#ifdef RETRO_TAPPING
- if (!is_tap_key(record->event.key)) {
+ if (!is_tap_action(action)) {
retro_tapping_counter = 0;
} else {
if (event.pressed) {
@@ -929,7 +929,15 @@ void clear_keyboard_but_mods_and_keys()
bool is_tap_key(keypos_t key)
{
action_t action = layer_switch_get_action(key);
+ return is_tap_action(action);
+}
+/** \brief Utilities for actions. (FIXME: Needs better description)
+ *
+ * FIXME: Needs documentation.
+ */
+bool is_tap_action(action_t action)
+{
switch (action.kind.id) {
case ACT_LMODS_TAP:
case ACT_RMODS_TAP: