diff options
author | Nick Brassel <nick@tzarc.org> | 2020-02-27 20:38:19 +1100 |
---|---|---|
committer | GitHub <noreply@github.com> | 2020-02-27 20:38:19 +1100 |
commit | 444fd3b1cc07d7f68aa37cbc9e38f2e4ed4d3ea7 (patch) | |
tree | 9198deb31eb8b79b3416f3806ef5d6b9da340829 /quantum/send_string_keycodes.h | |
parent | e18be6910493c132fa84be1f21a579fa9b9e12a9 (diff) | |
download | qmk_firmware-444fd3b1cc07d7f68aa37cbc9e38f2e4ed4d3ea7.tar.gz |
Add support for delays in send_string. (#8244)
Diffstat (limited to 'quantum/send_string_keycodes.h')
-rw-r--r-- | quantum/send_string_keycodes.h | 10 |
1 files changed, 7 insertions, 3 deletions
diff --git a/quantum/send_string_keycodes.h b/quantum/send_string_keycodes.h index b4a50f84d..86dc8bf00 100644 --- a/quantum/send_string_keycodes.h +++ b/quantum/send_string_keycodes.h @@ -382,13 +382,17 @@ #define ADD_SLASH_X(y) STRINGIZE(\x##y) #define SYMBOL_STR(x) ADD_SLASH_X(x) +#define SS_QMK_PREFIX 1 + #define SS_TAP_CODE 1 #define SS_DOWN_CODE 2 #define SS_UP_CODE 3 +#define SS_DELAY_CODE 4 -#define SS_TAP(keycode) "\1" SYMBOL_STR(keycode) -#define SS_DOWN(keycode) "\2" SYMBOL_STR(keycode) -#define SS_UP(keycode) "\3" SYMBOL_STR(keycode) +#define SS_TAP(keycode) "\1\1" SYMBOL_STR(keycode) +#define SS_DOWN(keycode) "\1\2" SYMBOL_STR(keycode) +#define SS_UP(keycode) "\1\3" SYMBOL_STR(keycode) +#define SS_DELAY(msecs) "\1\4" STRINGIZE(msecs) "|" // `string` arguments must not be parenthesized #define SS_LCTL(string) SS_DOWN(X_LCTL) string SS_UP(X_LCTL) |