Skip to content

Commit

Permalink
[Keyboard] Add keyboard level encoder function for GMMK Pro (qmk#16721)
Browse files Browse the repository at this point in the history
  • Loading branch information
waffle87 authored and zykrah committed Jul 2, 2022
1 parent 7f0dd06 commit 8961872
Showing 1 changed file with 14 additions and 0 deletions.
14 changes: 14 additions & 0 deletions keyboards/gmmk/pro/pro.c
Original file line number Diff line number Diff line change
Expand Up @@ -14,3 +14,17 @@
* along with this program. If not, see <http://www.gnu.org/licenses/>.
*/
#include "pro.h"

#ifdef ENCODER_ENABLE
bool encoder_update_kb(uint8_t index, bool clockwise) {
if (!encoder_update_user(index, clockwise)) {
return false;
}
if (clockwise) {
tap_code_delay(KC_VOLU, 10);
} else {
tap_code_delay(KC_VOLD, 10);
}
return false;
}
#endif

0 comments on commit 8961872

Please sign in to comment.