i3-sway: allow "container" and "output" in focus.mouseWarping (#3154)
Allow specifying which kind of mouseWarping to use since sway supports `mouse_warping output|container|none`.
This commit is contained in:
parent
b382b59faf
commit
c5b4177bda
|
@ -508,7 +508,10 @@ in {
|
|||
};
|
||||
|
||||
mouseWarping = mkOption {
|
||||
type = types.bool;
|
||||
type = if isSway then
|
||||
types.oneOf [ types.bool (types.enum [ "container" "output" ]) ]
|
||||
else
|
||||
types.bool;
|
||||
default = true;
|
||||
description = ''
|
||||
Whether mouse cursor should be warped to the center of the window when switching focus
|
||||
|
|
|
@ -273,7 +273,14 @@ let
|
|||
"focus_wrapping ${lib.hm.booleans.yesNo focus.forceWrapping}"
|
||||
"focus_follows_mouse ${focus.followMouse}"
|
||||
"focus_on_window_activation ${focus.newWindow}"
|
||||
"mouse_warping ${if focus.mouseWarping then "output" else "none"}"
|
||||
"mouse_warping ${
|
||||
if builtins.isString (focus.mouseWarping) then
|
||||
focus.mouseWarping
|
||||
else if focus.mouseWarping then
|
||||
"output"
|
||||
else
|
||||
"none"
|
||||
}"
|
||||
"workspace_layout ${workspaceLayout}"
|
||||
"workspace_auto_back_and_forth ${
|
||||
lib.hm.booleans.yesNo workspaceAutoBackAndForth
|
||||
|
|
Loading…
Reference in a new issue