diff --git a/users/drashna/drashna.c b/users/drashna/drashna.c index 1c353940..d7002d63 100644 --- a/users/drashna/drashna.c +++ b/users/drashna/drashna.c @@ -197,7 +197,7 @@ __attribute__((weak)) layer_state_t default_layer_state_set_keymap(layer_state_t layer_state_t default_layer_state_set_user(layer_state_t state) { state = default_layer_state_set_keymap(state); //#if 0 -# if defined(RGBLIGHT_ENABLE) || defined(RGB_MATRIX_ENABLE) +# if (defined(RGBLIGHT_ENABLE) || defined(RGB_MATRIX_ENABLE)) state = layer_state_set_rgb_light(state); # endif // RGBLIGHT_ENABLE //#endif diff --git a/users/drashna/drashna.h b/users/drashna/drashna.h index 588525a7..66b7bb1b 100644 --- a/users/drashna/drashna.h +++ b/users/drashna/drashna.h @@ -21,6 +21,7 @@ along with this program. If not, see . #include "version.h" #include "eeprom.h" #include "wrappers.h" +#include "process_records.h" enum userspace_layers { _QWERTY = 0, @@ -38,9 +39,34 @@ enum userspace_layers { _ADJUST, }; +bool mod_key_press_timer(uint16_t code, uint16_t mod_code, bool pressed); +bool mod_key_press(uint16_t code, uint16_t mod_code, bool pressed, uint16_t this_timer); +void matrix_init_keymap(void); +void shutdown_keymap(void); +void suspend_power_down_keymap(void); +void suspend_wakeup_init_keymap(void); +void matrix_scan_keymap(void); +layer_state_t layer_state_set_keymap(layer_state_t state); +layer_state_t default_layer_state_set_keymap(layer_state_t state); +void led_set_keymap(uint8_t usb_led); +void eeconfig_init_keymap(void); +bool hasAllBitsInMask(uint8_t value, uint8_t mask); + +// clang-format off +typedef union { + uint32_t raw; + struct { + bool rgb_layer_change :1; + bool swapped_numbers :1; + bool rgb_matrix_idle_anim :1; + }; +} userspace_config_t; +// clang-format on + +extern userspace_config_t userspace_config; + #if !defined(DROP_ALT) - #include "process_records.h" #ifdef TAP_DANCE_ENABLE # include "tap_dances.h" #endif // TAP_DANCE_ENABLE @@ -55,31 +81,7 @@ enum userspace_layers { #endif /* Define layer names */ - bool mod_key_press_timer(uint16_t code, uint16_t mod_code, bool pressed); - bool mod_key_press(uint16_t code, uint16_t mod_code, bool pressed, uint16_t this_timer); - void matrix_init_keymap(void); - void shutdown_keymap(void); - void suspend_power_down_keymap(void); - void suspend_wakeup_init_keymap(void); - void matrix_scan_keymap(void); - layer_state_t layer_state_set_keymap(layer_state_t state); - layer_state_t default_layer_state_set_keymap(layer_state_t state); - void led_set_keymap(uint8_t usb_led); - void eeconfig_init_keymap(void); - bool hasAllBitsInMask(uint8_t value, uint8_t mask); - // clang-format off - typedef union { - uint32_t raw; - struct { - bool rgb_layer_change :1; - bool swapped_numbers :1; - bool rgb_matrix_idle_anim :1; - }; - } userspace_config_t; - // clang-format on - - extern userspace_config_t userspace_config; /* Custom Keycodes for Diablo 3 layer diff --git a/users/drashna/rules.mk b/users/drashna/rules.mk index 80d204fc..36908518 100644 --- a/users/drashna/rules.mk +++ b/users/drashna/rules.mk @@ -1,6 +1,8 @@ +SRC += drashna.c +SRC += process_records.c + ifneq ($(strip $(DROP_ALT)), yes) - SRC += drashna.c \ - process_records.c + ifneq ($(PLATFORM),CHIBIOS) LTO_ENABLE = yes