aboutsummaryrefslogtreecommitdiff
path: root/keyboards/ncc1701kb/keymaps/default/keymap.c
diff options
context:
space:
mode:
Diffstat (limited to 'keyboards/ncc1701kb/keymaps/default/keymap.c')
-rw-r--r--keyboards/ncc1701kb/keymaps/default/keymap.c11
1 files changed, 6 insertions, 5 deletions
diff --git a/keyboards/ncc1701kb/keymaps/default/keymap.c b/keyboards/ncc1701kb/keymaps/default/keymap.c
index a3e3d819f..91158f12d 100644
--- a/keyboards/ncc1701kb/keymaps/default/keymap.c
+++ b/keyboards/ncc1701kb/keymaps/default/keymap.c
@@ -6,9 +6,9 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
6 * ,-----------------------. 6 * ,-----------------------.
7 * | << | MUTE | >> | ENCODER - PRESS (MUTE) / KNOB (VOLUME CONTROL) 7 * | << | MUTE | >> | ENCODER - PRESS (MUTE) / KNOB (VOLUME CONTROL)
8 * |-------+-------+-------| 8 * |-------+-------+-------|
9 * | STOP | PLAY | MEDIA | 9 * | STOP | PLAY | MEDIA |
10 * |-------+-------+-------| 10 * |-------+-------+-------|
11 * | CALC | MAIL | PC/FN | 11 * | CALC | MAIL | PC/FN |
12 * `-----------------------' 12 * `-----------------------'
13 */ 13 */
14[0] = LAYOUT( 14[0] = LAYOUT(
@@ -34,18 +34,19 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
34 34
35}; 35};
36 36
37void encoder_update_user(uint8_t index, bool clockwise) { 37bool encoder_update_user(uint8_t index, bool clockwise) {
38 if (index == 0) { /* First encoder */ 38 if (index == 0) { /* First encoder */
39 if (clockwise) { 39 if (clockwise) {
40 tap_code(KC_VOLU); 40 tap_code(KC_VOLU);
41 } else { 41 } else {
42 tap_code(KC_VOLD); 42 tap_code(KC_VOLD);
43 } 43 }
44 } else if (index == 1) { /* Second encoder */ 44 } else if (index == 1) { /* Second encoder */
45 if (clockwise) { 45 if (clockwise) {
46 tap_code(KC_VOLU); 46 tap_code(KC_VOLU);
47 } else { 47 } else {
48 tap_code(KC_VOLD); 48 tap_code(KC_VOLD);
49 } 49 }
50 } 50 }
51} \ No newline at end of file 51 return true;
52}