summaryrefslogtreecommitdiff
path: root/users/drashna/process_records.c
diff options
context:
space:
mode:
Diffstat (limited to 'users/drashna/process_records.c')
-rw-r--r--users/drashna/process_records.c62
1 files changed, 24 insertions, 38 deletions
diff --git a/users/drashna/process_records.c b/users/drashna/process_records.c
index ef901226e0..124354a5bc 100644
--- a/users/drashna/process_records.c
+++ b/users/drashna/process_records.c
@@ -29,10 +29,10 @@ bool process_record_user(uint16_t keycode, keyrecord_t *record) {
// If console is enabled, it will print the matrix position and status of each key pressed
#ifdef KEYLOGGER_ENABLE
uprintf("KL: kc: 0x%04X, col: %2u, row: %2u, pressed: %b, time: %5u, int: %b, count: %u\n", keycode, record->event.key.col, record->event.key.row, record->event.pressed, record->event.time, record->tap.interrupted, record->tap.count);
-#endif // KEYLOGGER_ENABLE
+#endif // KEYLOGGER_ENABLE
#ifdef OLED_DRIVER_ENABLE
process_record_user_oled(keycode, record);
-#endif // OLED
+#endif // OLED
if (!(process_record_keymap(keycode, record) && process_record_secrets(keycode, record)
#ifdef RGB_MATRIX_ENABLE
@@ -59,7 +59,7 @@ bool process_record_user(uint16_t keycode, keyrecord_t *record) {
}
break;
- case KC_MAKE: // Compiles the firmware, and adds the flash command based on keyboard bootloader
+ case KC_MAKE: // Compiles the firmware, and adds the flash command based on keyboard bootloader
if (!record->event.pressed) {
#ifndef MAKE_BOOTLOADER
uint8_t temp_mod = mod_config(get_mods());
@@ -90,56 +90,44 @@ bool process_record_user(uint16_t keycode, keyrecord_t *record) {
break;
- case VRSN: // Prints firmware version
- if (record->event.pressed) {
- send_string_with_delay_P(PSTR(QMK_KEYBOARD "/" QMK_KEYMAP " @ " QMK_VERSION ", Built on: " QMK_BUILDDATE), TAP_CODE_DELAY);
- }
+ case VRSN: // Prints firmware version
+ if (record->event.pressed) { send_string_with_delay_P(PSTR(QMK_KEYBOARD "/" QMK_KEYMAP " @ " QMK_VERSION ", Built on: " QMK_BUILDDATE), TAP_CODE_DELAY); }
break;
- case KC_DIABLO_CLEAR: // reset all Diablo timers, disabling them
+ case KC_DIABLO_CLEAR: // reset all Diablo timers, disabling them
#ifdef TAP_DANCE_ENABLE
if (record->event.pressed) {
- for (uint8_t index = 0; index < 4; index++) {
- diablo_timer[index].key_interval = 0;
- }
+ for (uint8_t index = 0; index < 4; index++) { diablo_timer[index].key_interval = 0; }
}
-#endif // TAP_DANCE_ENABLE
+#endif // TAP_DANCE_ENABLE
break;
- case KC_CCCV: // One key copy/paste
+ case KC_CCCV: // One key copy/paste
if (record->event.pressed) {
copy_paste_timer = timer_read();
} else {
- if (timer_elapsed(copy_paste_timer) > TAPPING_TERM) { // Hold, copy
+ if (timer_elapsed(copy_paste_timer) > TAPPING_TERM) { // Hold, copy
tap_code16(LCTL(KC_C));
- } else { // Tap, paste
+ } else { // Tap, paste
tap_code16(LCTL(KC_V));
}
}
break;
#ifdef UNICODE_ENABLE
- case UC_FLIP: // (ノಠ痊ಠ)ノ彡┻━┻
- if (record->event.pressed) {
- send_unicode_string("(ノಠ痊ಠ)ノ彡┻━┻");
- }
+ case UC_FLIP: // (ノಠ痊ಠ)ノ彡┻━┻
+ if (record->event.pressed) { send_unicode_string("(ノಠ痊ಠ)ノ彡┻━┻"); }
break;
- case UC_TABL: // ┬─┬ノ( º _ ºノ)
- if (record->event.pressed) {
- send_unicode_string("┬─┬ノ( º _ ºノ)");
- }
+ case UC_TABL: // ┬─┬ノ( º _ ºノ)
+ if (record->event.pressed) { send_unicode_string("┬─┬ノ( º _ ºノ)"); }
break;
- case UC_SHRG: // ¯\_(ツ)_/¯
- if (record->event.pressed) {
- send_unicode_string("¯\\_(ツ)_/¯");
- }
+ case UC_SHRG: // ¯\_(ツ)_/¯
+ if (record->event.pressed) { send_unicode_string("¯\\_(ツ)_/¯"); }
break;
- case UC_DISA: // ಠ_ಠ
- if (record->event.pressed) {
- send_unicode_string("ಠ_ಠ");
- }
+ case UC_DISA: // ಠ_ಠ
+ if (record->event.pressed) { send_unicode_string("ಠ_ಠ"); }
break;
#endif
- case KC_RGB_T: // This allows me to use underglow as layer indication, or as normal
+ case KC_RGB_T: // This allows me to use underglow as layer indication, or as normal
#if defined(RGBLIGHT_ENABLE) || defined(RGB_MATRIX_ENABLE)
if (record->event.pressed) {
userspace_config.rgb_layer_change ^= 1;
@@ -149,14 +137,14 @@ bool process_record_user(uint16_t keycode, keyrecord_t *record) {
# if defined(RGBLIGHT_ENABLE) && defined(RGB_MATRIX_ENABLE)
rgblight_enable_noeeprom();
# endif
- layer_state_set(layer_state); // This is needed to immediately set the layer color (looks better)
+ layer_state_set(layer_state); // This is needed to immediately set the layer color (looks better)
# if defined(RGBLIGHT_ENABLE) && defined(RGB_MATRIX_ENABLE)
} else {
rgblight_disable_noeeprom();
# endif
}
}
-#endif // RGBLIGHT_ENABLE
+#endif // RGBLIGHT_ENABLE
break;
#if defined(RGBLIGHT_ENABLE) || defined(RGB_MATRIX_ENABLE)
@@ -176,7 +164,7 @@ bool process_record_user(uint16_t keycode, keyrecord_t *record) {
}
return false;
break;
- case RGB_MODE_FORWARD ... RGB_MODE_GRADIENT: // quantum_keycodes.h L400 for definitions
+ case RGB_MODE_FORWARD ... RGB_MODE_GRADIENT: // quantum_keycodes.h L400 for definitions
if (record->event.pressed) {
bool is_eeprom_updated;
# if defined(RGBLIGHT_ENABLE) && !defined(RGBLIGHT_DISABLE_KEYCODES)
@@ -194,9 +182,7 @@ bool process_record_user(uint16_t keycode, keyrecord_t *record) {
is_eeprom_updated = true;
}
# endif
- if (is_eeprom_updated) {
- eeconfig_update_user(userspace_config.raw);
- }
+ if (is_eeprom_updated) { eeconfig_update_user(userspace_config.raw); }
}
#endif
}