X-Git-Url: https://git.donarmstrong.com/?a=blobdiff_plain;ds=sidebyside;f=common%2Faction.h;h=8f1f5b7986add2ed2028423d8c75f5f731bb04ec;hb=7e5081b5a8f2c6e0c3c8d2dc73717c0b3597ef84;hp=5f659337f9706fba99b6e9202728fed588b998db;hpb=ebe798f081ce018826dc882a40fc77ec8a0ad023;p=tmk_firmware.git diff --git a/common/action.h b/common/action.h index 5f65933..8f1f5b7 100644 --- a/common/action.h +++ b/common/action.h @@ -25,18 +25,20 @@ along with this program. If not, see . #include "action_macro.h" +/* tapping count and state */ +typedef struct { + bool interrupted :1; + bool reserved2 :1; + bool reserved1 :1; + bool reserved0 :1; + uint8_t count :4; +} tap_t; + /* Key event container for recording */ typedef struct { keyevent_t event; #ifndef NO_ACTION_TAPPING - /* tapping count and state */ - struct { - bool interrupted :1; - bool reserved2 :1; - bool reserved1 :1; - bool reserved0 :1; - uint8_t count :4; - } tap; + tap_t tap; #endif } keyrecord_t; @@ -48,7 +50,7 @@ void action_exec(keyevent_t event); action_t action_for_key(uint8_t layer, key_t key); /* macro */ -const prog_macro_t *action_get_macro(keyrecord_t *record, uint8_t id, uint8_t opt); +const macro_t *action_get_macro(keyrecord_t *record, uint8_t id, uint8_t opt); /* user defined special function */ void action_function(keyrecord_t *record, uint8_t id, uint8_t opt);