feat(q5_max): map dip-switch to RGB effects (heatmap / solid white)
Replace the Win/Mac default-layer switch with an RGB effect toggle: - Win side → solid white backlight - Mac side → typing heatmap Add a weak dip_switch_update_keymap() hook in q5_max.c to work around factory_test.c already owning dip_switch_update_user().
This commit is contained in:
@@ -29,11 +29,16 @@
|
||||
|
||||
|
||||
#ifdef DIP_SWITCH_ENABLE
|
||||
// Weak hook — override in keymap.c to handle dip-switch events
|
||||
// without conflicting with factory_test.c's dip_switch_update_user.
|
||||
__attribute__((weak)) void dip_switch_update_keymap(uint8_t index, bool active) {}
|
||||
|
||||
bool dip_switch_update_kb(uint8_t index, bool active) {
|
||||
if (index == 0) {
|
||||
default_layer_set(1UL << (active ? 2 : 0));
|
||||
}
|
||||
// if (index == 0) {
|
||||
// default_layer_set(1UL << (active ? 2 : 0));
|
||||
// }
|
||||
dip_switch_update_user(index, active);
|
||||
dip_switch_update_keymap(index, active);
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user