Merge pull request #62 from algernon/h/loop-hooks-after-scan

Call the loop hooks after doing the other loop actions
pull/64/head
Jesse Vincent 8 years ago committed by GitHub
commit cce029c34e

@ -21,14 +21,14 @@ custom_loop_t loopHooks[HOOK_MAX];
void void
Keyboardio_::loop(void) { Keyboardio_::loop(void) {
for (byte i = 0; loopHooks[i] != NULL && i < HOOK_MAX; i++) {
custom_loop_t hook = loopHooks[i];
(*hook)();
}
KeyboardHardware.scan_matrix(); KeyboardHardware.scan_matrix();
LEDControl.update(); LEDControl.update();
Keyboard.sendReport(); Keyboard.sendReport();
Keyboard.releaseAll(); Keyboard.releaseAll();
for (byte i = 0; loopHooks[i] != NULL && i < HOOK_MAX; i++) {
custom_loop_t hook = loopHooks[i];
(*hook)();
}
} }

Loading…
Cancel
Save