qmk_firmware/keyboards/xiudi/xd60/xd60.c
Joel Challis 99cd0b13e1
Refactor some led_set_kb instances (#19179)
* Refactor some led_set_kb instances

* Apply suggestions from code review

Co-authored-by: Ryan <fauxpark@gmail.com>

Co-authored-by: Ryan <fauxpark@gmail.com>
2022-12-09 01:42:22 +00:00

21 lines
439 B
C

#include "xd60.h"
extern inline void xd60_caps_led_on(void);
extern inline void xd60_bl_led_on(void);
extern inline void xd60_caps_led_off(void);
extern inline void xd60_bl_led_off(void);
bool led_update_kb(led_t led_state) {
bool res = led_update_user(led_state);
if(res) {
if (led_state.caps_lock) {
xd60_caps_led_on();
} else {
xd60_caps_led_off();
}
}
return res;
}