Adapt IdleLEDs plugin to KeyEvent handlers

Signed-off-by: Michael Richters <gedankenexperimenter@gmail.com>
pull/1024/head
Michael Richters 4 years ago
parent 352fa3fb70
commit a734d6d8b4
No known key found for this signature in database
GPG Key ID: 1288FD13E4EEF0C0

@ -49,8 +49,7 @@ EventHandlerResult IdleLEDs::beforeEachCycle() {
return EventHandlerResult::OK;
}
EventHandlerResult IdleLEDs::onKeyswitchEvent(Key &mapped_key, KeyAddr key_addr, uint8_t key_state) {
EventHandlerResult IdleLEDs::onKeyEvent(KeyEvent &event) {
if (idle_) {
::LEDControl.enable();
idle_ = false;

@ -33,7 +33,7 @@ class IdleLEDs: public kaleidoscope::Plugin {
static void setIdleTimeoutSeconds(uint32_t new_limit);
EventHandlerResult beforeEachCycle();
EventHandlerResult onKeyswitchEvent(Key &mapped_key, KeyAddr key_addr, uint8_t key_state);
EventHandlerResult onKeyEvent(KeyEvent &event);
private:
static bool idle_;

Loading…
Cancel
Save