diff options
Diffstat (limited to 'keyboards/dmqdesign/spin/keymaps/default/keymap.c')
-rw-r--r-- | keyboards/dmqdesign/spin/keymaps/default/keymap.c | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/keyboards/dmqdesign/spin/keymaps/default/keymap.c b/keyboards/dmqdesign/spin/keymaps/default/keymap.c index 0b5e6bd0b..ea6b518c3 100644 --- a/keyboards/dmqdesign/spin/keymaps/default/keymap.c +++ b/keyboards/dmqdesign/spin/keymaps/default/keymap.c | |||
@@ -24,24 +24,25 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = { | |||
24 | ), | 24 | ), |
25 | }; | 25 | }; |
26 | 26 | ||
27 | void encoder_update_user(uint8_t index, bool clockwise) { | 27 | bool encoder_update_user(uint8_t index, bool clockwise) { |
28 | if (index == 0) { /* First encoder */ | 28 | if (index == 0) { /* First encoder */ |
29 | if (clockwise) { | 29 | if (clockwise) { |
30 | rgblight_increase_hue(); //Cycle through the RGB hue | 30 | rgblight_increase_hue(); //Cycle through the RGB hue |
31 | } else { | 31 | } else { |
32 | rgblight_decrease_hue(); | 32 | rgblight_decrease_hue(); |
33 | } | 33 | } |
34 | } else if (index == 1) { /* Second encoder */ | 34 | } else if (index == 1) { /* Second encoder */ |
35 | if (clockwise) { | 35 | if (clockwise) { |
36 | tap_code(KC_VOLU); //Example of using tap_code which lets you use keycodes outside of the keymap | 36 | tap_code(KC_VOLU); //Example of using tap_code which lets you use keycodes outside of the keymap |
37 | } else { | 37 | } else { |
38 | tap_code(KC_VOLD); | 38 | tap_code(KC_VOLD); |
39 | } | 39 | } |
40 | } else if (index == 2) { /* Third encoder */ | 40 | } else if (index == 2) { /* Third encoder */ |
41 | if (clockwise) { | 41 | if (clockwise) { |
42 | rgblight_increase_val(); //Change brightness on the RGB LEDs | 42 | rgblight_increase_val(); //Change brightness on the RGB LEDs |
43 | } else { | 43 | } else { |
44 | rgblight_decrease_val(); | 44 | rgblight_decrease_val(); |
45 | } | 45 | } |
46 | } | 46 | } |
47 | return true; | ||
47 | } | 48 | } |