Update LED/RGB Matrix flag function behavior (#17651)
This commit is contained in:
@ -731,10 +731,20 @@ void rgb_matrix_decrease_speed(void) {
|
||||
rgb_matrix_decrease_speed_helper(true);
|
||||
}
|
||||
|
||||
void rgb_matrix_set_flags_eeprom_helper(led_flags_t flags, bool write_to_eeprom) {
|
||||
rgb_matrix_config.flags = flags;
|
||||
eeconfig_flag_rgb_matrix(write_to_eeprom);
|
||||
dprintf("rgb matrix set speed [%s]: %u\n", (write_to_eeprom) ? "EEPROM" : "NOEEPROM", rgb_matrix_config.flags);
|
||||
}
|
||||
|
||||
led_flags_t rgb_matrix_get_flags(void) {
|
||||
return rgb_matrix_config.flags;
|
||||
}
|
||||
|
||||
void rgb_matrix_set_flags(led_flags_t flags) {
|
||||
rgb_matrix_config.flags = flags;
|
||||
rgb_matrix_set_flags_eeprom_helper(flags, true);
|
||||
}
|
||||
|
||||
void rgb_matrix_set_flags_noeeprom(led_flags_t flags) {
|
||||
rgb_matrix_set_flags_eeprom_helper(flags, false);
|
||||
}
|
||||
|
Reference in New Issue
Block a user