diff options
Diffstat (limited to '.config/hypr/macros.m4')
-rw-r--r-- | .config/hypr/macros.m4 | 12 |
1 files changed, 11 insertions, 1 deletions
diff --git a/.config/hypr/macros.m4 b/.config/hypr/macros.m4 index f466f63..db542df 100644 --- a/.config/hypr/macros.m4 +++ b/.config/hypr/macros.m4 @@ -8,7 +8,17 @@ define(__submap, [ submap = reset ]) +define(__bindX, [ + ifelse([$#], 4, [ + bind$1 = $2, $3, exec, exec $4 2>/dev/null >&2 + ], [ + bind$1 = $modkey, $2, exec, exec $3 2>/dev/null >&2 + ]) +]) + +define(__bind, [__bindX(, $@)]) +define(__binde, [__bindX(e,$@)]) define(__subbind, [ - bind = , $1, exec, exec $2 2>/dev/null + __bindX(,,$@) bind = , $1, submap, reset ]) |