Skip to content

Commit

Permalink
Check if the runtime has leds
Browse files Browse the repository at this point in the history
Signed-off-by: Evy Bongers <[email protected]>
  • Loading branch information
EvyBongers committed Dec 2, 2023
1 parent f0365d6 commit d6f05ee
Showing 1 changed file with 3 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -55,6 +55,9 @@ EventHandlerResult ColormapOverlay::onSetup() {
}

void ColormapOverlay::setKeyboardLEDColors() {
if (!Runtime.has_leds)
return;

for (auto key_addr : KeyAddr::all()) {
if (ColormapOverlay::hasOverlay(key_addr)) {
::LEDControl.setCrgbAt(KeyAddr(key_addr), selectedColor);
Expand Down

0 comments on commit d6f05ee

Please sign in to comment.