Skip to content

Commit

Permalink
Fix scroll up/down
Browse files Browse the repository at this point in the history
  • Loading branch information
bzgec committed Sep 19, 2024
1 parent 8be1261 commit 6f95ddd
Showing 1 changed file with 15 additions and 6 deletions.
21 changes: 15 additions & 6 deletions config/corne.keymap
Original file line number Diff line number Diff line change
Expand Up @@ -105,11 +105,11 @@
***************************************************************************************************
* TODO:
***************************************************************************************************
* - wheel up/down not working
*
*/

#include <behaviors.dtsi>
#include <behaviors/mouse_keys.dtsi>
#include <dt-bindings/zmk/keys.h>
#include <dt-bindings/zmk/bt.h>
#include <dt-bindings/zmk/ext_power.h>
Expand Down Expand Up @@ -142,6 +142,15 @@
// On hold: L_ZMK (ZMK layer)
#define TAB_L_ZMK &lt L_ZMK TAB

// https://gist.github.com/krissen/dd27082e7ab0575619c7a31f4d2ec7ae
//#undef SCRL_UP
//#undef SCRL_DOWN
//#undef SCRL_LEFT
//#undef SCRL_RIGHT
//#define SCRL_UP MOVE_Y(ZMK_MOUSE_DEFAULT_SCRL_VAL)
//#define SCRL_DOWN MOVE_Y(-ZMK_MOUSE_DEFAULT_SCRL_VAL)
//#define SCRL_LEFT MOVE_X(-ZMK_MOUSE_DEFAULT_SCRL_VAL)
//#define SCRL_RIGHT MOVE_X(ZMK_MOUSE_DEFAULT_SCRL_VAL)

// https://zmk.dev/docs/features/debouncing
&kscan0 {
Expand Down Expand Up @@ -226,10 +235,10 @@
// | SHFT | Del | | | | | | Undo | Redo | | | Del | |
// | GUI | CTRL | Enter | | Enter | EXT2 | L ALT |
bindings = <
___ &kp ESC &mkp MB4 &kp K_SCROLL_UP &mkp MB5 xxx &kp HOME &kp PG_DN &kp PG_UP &kp END xxx &kp PSCRN
xxx &kp BSPC xxx &kp K_SCROLL_DOWN xxx xxx &kp LEFT &kp DOWN &kp UP &kp RIGHT &kp BSPC &kp ESC
___ &kp DEL xxx xxx xxx xxx &kp UNDO &kp K_REDO xxx xxx &kp DEL ___
___ ___ &kp RET ___ &mo L_EXT2_LIN ___
___ &kp ESC &mkp MB4 &msc SCRL_UP &mkp MB5 xxx &kp HOME &kp PG_DN &kp PG_UP &kp END xxx &kp PSCRN
xxx &kp BSPC xxx &msc SCRL_DOWN xxx xxx &kp LEFT &kp DOWN &kp UP &kp RIGHT &kp BSPC &kp ESC
___ &kp DEL xxx xxx xxx xxx &kp UNDO &kp K_REDO xxx xxx &kp DEL ___
___ ___ &kp RET ___ &mo L_EXT2_LIN ___
>;
};
// Changing only
Expand Down Expand Up @@ -302,7 +311,7 @@
zmk_layer {
// -----------------------------------------------------------------------------------------
// | XXX | BT 0 | BT 1 | BT 2 | BT 3 | BT 4 | | | | | | | |
// | Reset | BTCLR | | EP ON | EP OFF | | | | To SI WIN | To SI WIN | | | |
// | Reset | BTCLR | | EP ON | EP OFF | | | | To SI LIN | To SI WIN | | | |
// | Bootl | | | | | | | | | | | | |
// | | | | | MS_MDL | MS_LEFT | MS_RIGHT |
bindings = <
Expand Down

0 comments on commit 6f95ddd

Please sign in to comment.