summaryrefslogtreecommitdiff
path: root/keyboards/bbrfkr/dynamis/dynamis.c
diff options
context:
space:
mode:
authorbbrfkr <bbrfkr@gmail.com>2022-08-29 13:47:30 +0900
committerGitHub <noreply@github.com>2022-08-28 21:47:30 -0700
commita2294bcc979c26eb60b6fcd0d1166952ed32fd3d (patch)
tree2a4233352477fea9924f718c482b3222deacff7e /keyboards/bbrfkr/dynamis/dynamis.c
parent38de991fda2bdb813b2acd067762a22c59607207 (diff)
[Keyboard] Update dynamis keyboard (#17625)
Co-authored-by: Drashna Jaelre <drashna@live.com>
Diffstat (limited to 'keyboards/bbrfkr/dynamis/dynamis.c')
-rw-r--r--keyboards/bbrfkr/dynamis/dynamis.c16
1 files changed, 6 insertions, 10 deletions
diff --git a/keyboards/bbrfkr/dynamis/dynamis.c b/keyboards/bbrfkr/dynamis/dynamis.c
index e7f780ef1a..8655cbc7bc 100644
--- a/keyboards/bbrfkr/dynamis/dynamis.c
+++ b/keyboards/bbrfkr/dynamis/dynamis.c
@@ -18,16 +18,12 @@
#ifdef ENCODER_ENABLE
bool encoder_update_kb(uint8_t index, bool clockwise) {
- if (!encoder_update_user(index, clockwise)) {
- return false;
+ if (!encoder_update_user(index, clockwise)) { return false; }
+ if (clockwise) {
+ tap_code(layer_state == 0 ? KC_WH_D : KC_VOLD);
+ } else {
+ tap_code(layer_state == 0 ? KC_WH_U : KC_VOLU);
}
- if (index == 0) { /* First encoder */
- if (clockwise) {
- tap_code(KC_WH_D);
- } else {
- tap_code(KC_WH_U);
- }
- }
- return false;
+ return true;
}
#endif