2018-07-08 14:11:02 +02:00
|
|
|
#include QMK_KEYBOARD_H
|
|
|
|
#include "split_util.h"
|
|
|
|
#include "keymap_xrows.h"
|
|
|
|
|
|
|
|
// keymaps definitions are moved to keymap_Xrows.c.
|
|
|
|
|
|
|
|
#ifdef RGBLIGHT_ENABLE
|
2022-06-18 23:37:51 +02:00
|
|
|
layer_state_t layer_state_set_keymap(layer_state_t state) {
|
2021-04-10 02:37:49 +02:00
|
|
|
rgblight_mode_noeeprom(RGBLIGHT_MODE_STATIC_LIGHT);
|
2022-06-18 23:37:51 +02:00
|
|
|
switch (get_highest_layer(state)) {
|
2021-04-10 02:37:49 +02:00
|
|
|
case L_EDVORAKJP_LOWER:
|
2022-10-28 00:50:14 +02:00
|
|
|
rgblight_sethsv_noeeprom(HSV_RED);
|
2021-04-10 02:37:49 +02:00
|
|
|
break;
|
|
|
|
case L_EDVORAKJP_RAISE:
|
2022-10-28 00:50:14 +02:00
|
|
|
rgblight_sethsv_noeeprom(HSV_GREEN);
|
2021-04-10 02:37:49 +02:00
|
|
|
break;
|
|
|
|
default: // for any other layers, or the default layer
|
|
|
|
rgblight_mode(RGBLIGHT_MODE_STATIC_GRADIENT + 3);
|
2022-10-28 00:50:14 +02:00
|
|
|
rgblight_sethsv(HSV_RED);
|
2021-04-10 02:37:49 +02:00
|
|
|
break;
|
|
|
|
}
|
|
|
|
return state;
|
2018-07-08 14:11:02 +02:00
|
|
|
}
|
|
|
|
#endif
|