diff options
| author | Fredrik Larsen <fredrikhl@users.noreply.github.com> | 2022-01-11 18:55:24 +0100 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2022-01-11 09:55:24 -0800 |
| commit | 052a59fc3bff180244268d0d3509a9d22a86c89d (patch) | |
| tree | c6c36409860757c1ff8e6543b878dea131c7ab75 | |
| parent | bda520198e573c4fcb0bc0af8d33085ad6e0f9c6 (diff) | |
| download | qmk_firmware-052a59fc3bff180244268d0d3509a9d22a86c89d.tar.gz qmk_firmware-052a59fc3bff180244268d0d3509a9d22a86c89d.zip | |
[Keyboard] Use correct callback in macro1 implementation (#15819)
| -rw-r--r-- | keyboards/macro1/macro1.c | 42 |
1 files changed, 22 insertions, 20 deletions
diff --git a/keyboards/macro1/macro1.c b/keyboards/macro1/macro1.c index b470ed523..f1fbed1d1 100644 --- a/keyboards/macro1/macro1.c +++ b/keyboards/macro1/macro1.c | |||
| @@ -1,29 +1,31 @@ | |||
| 1 | /* Copyright 2021 Laneware Peripherals | 1 | /* Copyright 2021 Laneware Peripherals |
| 2 | * | 2 | * |
| 3 | * This program is free software: you can redistribute it and/or modify | 3 | * This program is free software: you can redistribute it and/or modify |
| 4 | * it under the terms of the GNU General Public License as published by | 4 | * it under the terms of the GNU General Public License as published by |
| 5 | * the Free Software Foundation, either version 2 of the License, or | 5 | * the Free Software Foundation, either version 2 of the License, or |
| 6 | * (at your option) any later version. | 6 | * (at your option) any later version. |
| 7 | * | 7 | * |
| 8 | * This program is distributed in the hope that it will be useful, | 8 | * This program is distributed in the hope that it will be useful, |
| 9 | * but WITHOUT ANY WARRANTY; without even the implied warranty of | 9 | * but WITHOUT ANY WARRANTY; without even the implied warranty of |
| 10 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | 10 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
| 11 | * GNU General Public License for more details. | 11 | * GNU General Public License for more details. |
| 12 | * | 12 | * |
| 13 | * You should have received a copy of the GNU General Public License | 13 | * You should have received a copy of the GNU General Public License |
| 14 | * along with this program. If not, see <http://www.gnu.org/licenses/>. | 14 | * along with this program. If not, see <http://www.gnu.org/licenses/>. |
| 15 | */ | 15 | */ |
| 16 | |||
| 17 | #include "macro1.h" | 16 | #include "macro1.h" |
| 18 | 17 | ||
| 19 | bool encoder_update_user(uint8_t index, bool clockwise) { | 18 | |
| 19 | bool encoder_update_kb(uint8_t index, bool clockwise) { | ||
| 20 | if (!encoder_update_user(index, clockwise)) { | ||
| 21 | return false; | ||
| 22 | } | ||
| 20 | if (index == 0) { /* First encoder */ | 23 | if (index == 0) { /* First encoder */ |
| 21 | if (clockwise) { | 24 | if (clockwise) { |
| 22 | tap_code(KC_VOLU); | 25 | tap_code(KC_VOLU); |
| 23 | } else { | 26 | } else { |
| 24 | tap_code(KC_VOLD); | 27 | tap_code(KC_VOLD); |
| 25 | } | 28 | } |
| 26 | } | 29 | } |
| 27 | return false; | 30 | return false; |
| 28 | } | 31 | } |
| 29 | |||
