handleKeyswitchEvent: Fix a thinko that broke old-style plugins

Fixed a conditional so that the event handlers of old-style plugins will be
called. Without this, they don't, and old-style plugins that install event
handlers, would not work.

Signed-off-by: Gergely Nagy <algernon@keyboard.io>
pull/319/head
Gergely Nagy 7 years ago
parent bddfc7b607
commit e249fd2de6

@ -94,7 +94,7 @@ void handleKeyswitchEvent(Key mappedKey, byte row, byte col, uint8_t keyState) {
// Keypresses with out-of-bounds (row,col) start here in the processing chain // Keypresses with out-of-bounds (row,col) start here in the processing chain
// Legacy event handlers // Legacy event handlers
#if KALEIDOSCOPE_ENABLE_V1_API #if KALEIDOSCOPE_ENABLE_V1_PLUGIN_API
for (byte i = 0; Kaleidoscope.eventHandlers[i] != NULL && i < HOOK_MAX; i++) { for (byte i = 0; Kaleidoscope.eventHandlers[i] != NULL && i < HOOK_MAX; i++) {
Kaleidoscope_::eventHandlerHook handler = Kaleidoscope.eventHandlers[i]; Kaleidoscope_::eventHandlerHook handler = Kaleidoscope.eventHandlers[i];
mappedKey = (*handler)(mappedKey, row, col, keyState); mappedKey = (*handler)(mappedKey, row, col, keyState);

Loading…
Cancel
Save