Clean up some of the code

This commit is contained in:
Drashna Jaelre 2019-02-17 08:58:02 -08:00 committed by skullydazed
parent a2090d5e86
commit 7148c0b10c
2 changed files with 3 additions and 3 deletions

View File

@ -962,8 +962,7 @@ void send_char(char ascii_code) {
if (is_shifted) { register_code(KC_LSFT); } if (is_shifted) { register_code(KC_LSFT); }
if (is_alted) { register_code(KC_RALT); } if (is_alted) { register_code(KC_RALT); }
register_code(keycode); tap_code(keycode);
unregister_code(keycode);
if (is_alted) { unregister_code(KC_RALT); } if (is_alted) { unregister_code(KC_RALT); }
if (is_shifted) { unregister_code(KC_LSFT); } if (is_shifted) { unregister_code(KC_LSFT); }

View File

@ -206,6 +206,7 @@ extern uint32_t default_layer_state;
#define SEND_STRING(str) send_string_P(PSTR(str)) #define SEND_STRING(str) send_string_P(PSTR(str))
extern const bool ascii_to_shift_lut[0x80]; extern const bool ascii_to_shift_lut[0x80];
extern const bool ascii_to_alt_lut[0x80];
extern const uint8_t ascii_to_keycode_lut[0x80]; extern const uint8_t ascii_to_keycode_lut[0x80];
void send_string(const char *str); void send_string(const char *str);
void send_string_with_delay(const char *str, uint8_t interval); void send_string_with_delay(const char *str, uint8_t interval);