Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Remove useless LED/RGB_MATRIX_ENABLE ifdefs #23726

Merged
merged 1 commit into from
May 16, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions quantum/led_matrix/led_matrix.c
Original file line number Diff line number Diff line change
Expand Up @@ -82,7 +82,7 @@ static last_hit_t last_hit_buffer;
#endif // LED_MATRIX_KEYREACTIVE_ENABLED

// split led matrix
#if defined(LED_MATRIX_ENABLE) && defined(LED_MATRIX_SPLIT)
#if defined(LED_MATRIX_SPLIT)
const uint8_t k_led_matrix_split[2] = LED_MATRIX_SPLIT;
#endif

Expand Down Expand Up @@ -147,7 +147,7 @@ void led_matrix_set_value(int index, uint8_t value) {
}

void led_matrix_set_value_all(uint8_t value) {
#if defined(LED_MATRIX_ENABLE) && defined(LED_MATRIX_SPLIT)
#if defined(LED_MATRIX_SPLIT)
for (uint8_t i = 0; i < LED_MATRIX_LED_COUNT; i++)
led_matrix_set_value(i, value);
#else
Expand Down
4 changes: 2 additions & 2 deletions quantum/rgb_matrix/rgb_matrix.c
Original file line number Diff line number Diff line change
Expand Up @@ -84,7 +84,7 @@ static last_hit_t last_hit_buffer;
#endif // RGB_MATRIX_KEYREACTIVE_ENABLED

// split rgb matrix
#if defined(RGB_MATRIX_ENABLE) && defined(RGB_MATRIX_SPLIT)
#if defined(RGB_MATRIX_SPLIT)
const uint8_t k_rgb_matrix_split[2] = RGB_MATRIX_SPLIT;
#endif

Expand Down Expand Up @@ -148,7 +148,7 @@ void rgb_matrix_set_color(int index, uint8_t red, uint8_t green, uint8_t blue) {
}

void rgb_matrix_set_color_all(uint8_t red, uint8_t green, uint8_t blue) {
#if defined(RGB_MATRIX_ENABLE) && defined(RGB_MATRIX_SPLIT)
#if defined(RGB_MATRIX_SPLIT)
for (uint8_t i = 0; i < RGB_MATRIX_LED_COUNT; i++)
rgb_matrix_set_color(i, red, green, blue);
#else
Expand Down
2 changes: 1 addition & 1 deletion quantum/rgb_matrix/rgb_matrix_drivers.c
Original file line number Diff line number Diff line change
Expand Up @@ -164,7 +164,7 @@ static void flush(void) {

// Set an led in the buffer to a color
static inline void setled(int i, uint8_t r, uint8_t g, uint8_t b) {
# if defined(RGB_MATRIX_ENABLE) && defined(RGB_MATRIX_SPLIT)
# if defined(RGB_MATRIX_SPLIT)
const uint8_t k_rgb_matrix_split[2] = RGB_MATRIX_SPLIT;
if (!is_keyboard_left()) {
if (i >= k_rgb_matrix_split[0]) {
Expand Down
Loading