From 63646e8906e062d1c1de3925cba70c4e3426a855 Mon Sep 17 00:00:00 2001 From: QMK Bot Date: Sat, 12 Feb 2022 10:29:31 -0800 Subject: Format code according to conventions (#16322) --- quantum/send_string.c | 22 +++++++++++++++------- 1 file changed, 15 insertions(+), 7 deletions(-) (limited to 'quantum/send_string.c') diff --git a/quantum/send_string.c b/quantum/send_string.c index 1a7f7a1315..0de12ba12d 100644 --- a/quantum/send_string.c +++ b/quantum/send_string.c @@ -142,9 +142,13 @@ __attribute__((weak)) const uint8_t ascii_to_keycode_lut[128] PROGMEM = { // Note: we bit-pack in "reverse" order to optimize loading #define PGM_LOADBIT(mem, pos) ((pgm_read_byte(&((mem)[(pos) / 8])) >> ((pos) % 8)) & 0x01) -void send_string(const char *str) { send_string_with_delay(str, 0); } +void send_string(const char *str) { + send_string_with_delay(str, 0); +} -void send_string_P(const char *str) { send_string_with_delay_P(str, 0); } +void send_string_P(const char *str) { + send_string_with_delay_P(str, 0); +} void send_string_with_delay(const char *str, uint8_t interval) { while (1) { @@ -173,7 +177,8 @@ void send_string_with_delay(const char *str, uint8_t interval) { ms += keycode - '0'; keycode = *(++str); } - while (ms--) wait_ms(1); + while (ms--) + wait_ms(1); } } else { send_char(ascii_code); @@ -182,7 +187,8 @@ void send_string_with_delay(const char *str, uint8_t interval) { // interval { uint8_t ms = interval; - while (ms--) wait_ms(1); + while (ms--) + wait_ms(1); } } } @@ -214,7 +220,8 @@ void send_string_with_delay_P(const char *str, uint8_t interval) { ms += keycode - '0'; keycode = pgm_read_byte(++str); } - while (ms--) wait_ms(1); + while (ms--) + wait_ms(1); } } else { send_char(ascii_code); @@ -223,14 +230,15 @@ void send_string_with_delay_P(const char *str, uint8_t interval) { // interval { uint8_t ms = interval; - while (ms--) wait_ms(1); + while (ms--) + wait_ms(1); } } } void send_char(char ascii_code) { #if defined(AUDIO_ENABLE) && defined(SENDSTRING_BELL) - if (ascii_code == '\a') { // BEL + if (ascii_code == '\a') { // BEL PLAY_SONG(bell_song); return; } -- cgit v1.2.3