diff options
author | Gergely Nagy <algernon@keyboard.io> | 2020-01-08 19:44:31 +0100 |
---|---|---|
committer | Gergely Nagy <algernon@keyboard.io> | 2020-01-08 19:44:31 +0100 |
commit | 8f193dfdfff20c1a35d8cf3eb04e214b11f03485 (patch) | |
tree | 66f3fa738ebefcf6bb282e7ffdda09a5b52d45ca | |
parent | d10ad2a9c2de3cda5b89a4e447e5d6291bd27575 (diff) | |
download | model01-firmware-8f193dfdfff20c1a35d8cf3eb04e214b11f03485.tar.gz model01-firmware-8f193dfdfff20c1a35d8cf3eb04e214b11f03485.tar.bz2 model01-firmware-8f193dfdfff20c1a35d8cf3eb04e214b11f03485.zip |
Use the new LEDControl.disable/LEDControl.enable methods
To toggle LEDs on suspend/resume, use the new LEDControl methods instead of the
old `LEDControl.paused` property.
Signed-off-by: Gergely Nagy <algernon@keyboard.io>
-rw-r--r-- | Model01-Firmware.ino | 7 |
1 files changed, 2 insertions, 5 deletions
diff --git a/Model01-Firmware.ino b/Model01-Firmware.ino index 9a97c83..01fe286 100644 --- a/Model01-Firmware.ino +++ b/Model01-Firmware.ino @@ -361,13 +361,10 @@ static kaleidoscope::plugin::LEDSolidColor solidViolet(130, 0, 120); void toggleLedsOnSuspendResume(kaleidoscope::plugin::HostPowerManagement::Event event) { switch (event) { case kaleidoscope::plugin::HostPowerManagement::Suspend: - LEDControl.set_all_leds_to({0, 0, 0}); - LEDControl.syncLeds(); - LEDControl.paused = true; + LEDControl.disable(); break; case kaleidoscope::plugin::HostPowerManagement::Resume: - LEDControl.paused = false; - LEDControl.refreshAll(); + LEDControl.enable(); break; case kaleidoscope::plugin::HostPowerManagement::Sleep: break; |