diff options
author | aszlig <aszlig@redmoonstudios.org> | 2017-04-24 12:02:10 +0200 |
---|---|---|
committer | aszlig <aszlig@redmoonstudios.org> | 2017-04-24 12:02:10 +0200 |
commit | 79e712822fcfe797c545e2db5bcef9a07b00b2e5 (patch) | |
tree | d87b6c295d6f7da5023b2564ebc397e61142fc6e /nixos/modules/services/x11/xserver.nix | |
parent | d7a8876c13f75e7a55e2f3cbc16346406e9abdf8 (diff) | |
download | nixlib-79e712822fcfe797c545e2db5bcef9a07b00b2e5.tar nixlib-79e712822fcfe797c545e2db5bcef9a07b00b2e5.tar.gz nixlib-79e712822fcfe797c545e2db5bcef9a07b00b2e5.tar.bz2 nixlib-79e712822fcfe797c545e2db5bcef9a07b00b2e5.tar.lz nixlib-79e712822fcfe797c545e2db5bcef9a07b00b2e5.tar.xz nixlib-79e712822fcfe797c545e2db5bcef9a07b00b2e5.tar.zst nixlib-79e712822fcfe797c545e2db5bcef9a07b00b2e5.zip |
nixos/xserver: Document xrandrHeads.apply
It was asked by @CMCDragonkai to elaborate on that, so let's just do this by actually providing a code comment. Signed-off-by: aszlig <aszlig@redmoonstudios.org>
Diffstat (limited to 'nixos/modules/services/x11/xserver.nix')
-rw-r--r-- | nixos/modules/services/x11/xserver.nix | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/nixos/modules/services/x11/xserver.nix b/nixos/modules/services/x11/xserver.nix index 9ac69195a679..20028d7eb6a8 100644 --- a/nixos/modules/services/x11/xserver.nix +++ b/nixos/modules/services/x11/xserver.nix @@ -374,6 +374,8 @@ in type = with types; listOf (coercedTo str (output: { inherit output; }) (submodule { options = xrandrOptions; })); + # Set primary to true for the first head if no other has been set + # primary already. apply = heads: let hasPrimary = any (x: x.primary) heads; firstPrimary = head heads // { primary = true; }; |