From a0fed0ea176d1c986e40fc4981b900509c90d66e Mon Sep 17 00:00:00 2001 From: Drashna Jaelre Date: Fri, 21 May 2021 23:17:32 -0700 Subject: Convert Encoder callbacks to be boolean functions (#12805) Co-authored-by: James Young <18669334+noroadsleft@users.noreply.github.com> --- users/kuchosauronad0/encoder.c | 3 ++- users/kuchosauronad0/encoder.h | 2 +- 2 files changed, 3 insertions(+), 2 deletions(-) (limited to 'users/kuchosauronad0') diff --git a/users/kuchosauronad0/encoder.c b/users/kuchosauronad0/encoder.c index 06b7b51233..9284a041c2 100644 --- a/users/kuchosauronad0/encoder.c +++ b/users/kuchosauronad0/encoder.c @@ -1,5 +1,5 @@ #include "encoder.h" -void encoder_update_user(uint8_t index, bool clockwise) { +bool encoder_update_user(uint8_t index, bool clockwise) { static uint16_t kc; uint8_t temp_mod = get_mods(); if (index == 0) { /* first encoder */ @@ -55,6 +55,7 @@ void encoder_update_user(uint8_t index, bool clockwise) { tap_code(KC_1); } } + return true; } const uint16_t PROGMEM encoder_actions[][9] = { \ // None CTRL ALT SHIFT GUI CTRL+ALT CTRL+SHFT ALT+SHFT HYPER diff --git a/users/kuchosauronad0/encoder.h b/users/kuchosauronad0/encoder.h index 2610c9677a..7b05aa4911 100644 --- a/users/kuchosauronad0/encoder.h +++ b/users/kuchosauronad0/encoder.h @@ -1,4 +1,4 @@ #pragma once #include "quantum.h" const uint16_t PROGMEM encoder_actions[][9]; -void encoder_update_user(uint8_t index, bool clockwise); +bool encoder_update_user(uint8_t index, bool clockwise); -- cgit v1.2.3