mirror of
https://github.com/Keychron/qmk_firmware.git
synced 2024-12-24 02:05:01 +06:00
[Keyboard] Add missing dip_switch_update_kb
for Keychron V2 (#19674)
This commit is contained in:
parent
4d180c935a
commit
695c4c6030
@ -26,6 +26,17 @@ const matrix_row_t matrix_mask[] = {
|
||||
|
||||
#ifdef DIP_SWITCH_ENABLE
|
||||
|
||||
bool dip_switch_update_kb(uint8_t index, bool active) {
|
||||
if (!dip_switch_update_user(index, active)) { return false;}
|
||||
if (index == 0) {
|
||||
default_layer_set(1UL << (active ? 1 : 0));
|
||||
}
|
||||
return true;
|
||||
}
|
||||
|
||||
#endif // DIP_SWITCH_ENABLE
|
||||
|
||||
#if defined(RGB_MATRIX_ENABLE) && defined(CAPS_LOCK_LED_INDEX)
|
||||
bool process_record_kb(uint16_t keycode, keyrecord_t *record) {
|
||||
if (!process_record_user(keycode, record)) { return false; }
|
||||
switch (keycode) {
|
||||
|
Loading…
Reference in New Issue
Block a user