Skip to content

Commit

Permalink
keycodes: fix LM()
Browse files Browse the repository at this point in the history
  • Loading branch information
xyzz committed Jun 4, 2024
1 parent 1154ce1 commit a76a79d
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 1 deletion.
2 changes: 1 addition & 1 deletion src/main/python/any_keycode.py
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@ def MO(layer): return (r("QK_MOMENTARY") | ((layer)&0xFF))
def DF(layer): return (r("QK_DEF_LAYER") | ((layer)&0xFF))
def TG(layer): return (r("QK_TOGGLE_LAYER") | ((layer)&0xFF))
def OSL(layer): return (r("QK_ONE_SHOT_LAYER") | ((layer)&0xFF))
def LM(layer, mod): return (r("QK_LAYER_MOD") | (((layer)&0xF) << 4) | ((mod)&0xF))
def LM(layer, mod): return (r("QK_LAYER_MOD") | (((layer)&0xF) << r("QMK_LM_SHIFT")) | ((mod)&0xF))
def OSM(mod): return (r("QK_ONE_SHOT_MOD") | ((mod)&0xFF))
def TT(layer): return (r("QK_LAYER_TAP_TOGGLE") | ((layer)&0xFF))
def MT(mod, kc): return (r("QK_MOD_TAP") | (((mod)&0x1F) << 8) | ((kc)&0xFF))
Expand Down
2 changes: 2 additions & 0 deletions src/main/python/keycodes/keycodes_v5.py
Original file line number Diff line number Diff line change
Expand Up @@ -555,6 +555,8 @@ class keycodes_v5:

"QK_KB": 0x5F80,
"QK_MACRO": 0x5F12,

"QMK_LM_SHIFT": 4,
}

masked = set()
Expand Down
2 changes: 2 additions & 0 deletions src/main/python/keycodes/keycodes_v6.py
Original file line number Diff line number Diff line change
Expand Up @@ -555,6 +555,8 @@ class keycodes_v6:
"FN_MO23": 0x7C78,

"QK_KB": 0x7E00,

"QMK_LM_SHIFT": 5,
}

masked = set()
Expand Down

0 comments on commit a76a79d

Please sign in to comment.