mirror of https://github.com/qmk/qmk_firmware
Update keymap.c
parent
84981f07be
commit
27dc8971fc
|
@ -78,38 +78,3 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
|
||||||
_______, _______, _______, _______, _______, _______, RGB_SAD, RGB_VAD, RGB_SAI, _______, _______)
|
_______, _______, _______, _______, _______, _______, RGB_SAD, RGB_VAD, RGB_SAI, _______, _______)
|
||||||
|
|
||||||
};
|
};
|
||||||
bool process_record_user(uint16_t keycode, keyrecord_t *record) {
|
|
||||||
switch (keycode) {
|
|
||||||
case DF(WIN_B):
|
|
||||||
if (record->event.pressed) {
|
|
||||||
set_single_persistent_default_layer(WIN_B);
|
|
||||||
}
|
|
||||||
return false;
|
|
||||||
case DF(MAC_B):
|
|
||||||
if (record->event.pressed) {
|
|
||||||
set_single_persistent_default_layer(MAC_B);
|
|
||||||
keymap_config.no_gui = 0;
|
|
||||||
eeconfig_update_keymap(keymap_config.raw);
|
|
||||||
}
|
|
||||||
return false;
|
|
||||||
case RGB_TOG:
|
|
||||||
if (record->event.pressed) {
|
|
||||||
switch (rgb_matrix_get_flags()) {
|
|
||||||
case LED_FLAG_ALL: {
|
|
||||||
rgb_matrix_set_flags(LED_FLAG_NONE);
|
|
||||||
rgb_matrix_set_color_all(0, 0, 0);
|
|
||||||
} break;
|
|
||||||
default: {
|
|
||||||
rgb_matrix_set_flags(LED_FLAG_ALL);
|
|
||||||
} break;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
if (!rgb_matrix_is_enabled()) {
|
|
||||||
rgb_matrix_set_flags(LED_FLAG_ALL);
|
|
||||||
rgb_matrix_enable();
|
|
||||||
}
|
|
||||||
return false;
|
|
||||||
default:
|
|
||||||
return true;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
Loading…
Reference in New Issue