|
|
@ -5,16 +5,29 @@
|
|
|
|
...
|
|
|
|
...
|
|
|
|
}:
|
|
|
|
}:
|
|
|
|
let
|
|
|
|
let
|
|
|
|
|
|
|
|
prgs = config.programs;
|
|
|
|
|
|
|
|
servDM = config.services.desktopManager;
|
|
|
|
|
|
|
|
xDM = config.services.xserver.desktopManager;
|
|
|
|
cfg = config.x-banananetwork.improvedDefaults;
|
|
|
|
cfg = config.x-banananetwork.improvedDefaults;
|
|
|
|
in
|
|
|
|
in
|
|
|
|
{
|
|
|
|
{
|
|
|
|
|
|
|
|
|
|
|
|
config = lib.mkIf cfg.enable (
|
|
|
|
options = {
|
|
|
|
let
|
|
|
|
|
|
|
|
prgs = config.programs;
|
|
|
|
services.wayland.enable = lib.mkEnableOption ''
|
|
|
|
servDM = config.services.desktopManager;
|
|
|
|
sensible defaults for Wayland sessions.
|
|
|
|
xDM = config.services.xserver.desktopManager;
|
|
|
|
|
|
|
|
waylandEnabled = builtins.any (x: x) ([
|
|
|
|
Be aware that a Wayland compositor or desktop environment is not enabled automatically
|
|
|
|
|
|
|
|
as there is no main implementation of Wayland.
|
|
|
|
|
|
|
|
'';
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
};
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
config = lib.mkMerge [
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
(lib.mkIf (cfg.enable) {
|
|
|
|
|
|
|
|
# auto detect if a wayland compatible compositor is already enabled
|
|
|
|
|
|
|
|
services.wayland.enable = builtins.any (x: x) ([
|
|
|
|
prgs.hyprland.enable
|
|
|
|
prgs.hyprland.enable
|
|
|
|
prgs.miriway.enable
|
|
|
|
prgs.miriway.enable
|
|
|
|
prgs.river.enable
|
|
|
|
prgs.river.enable
|
|
|
@ -24,13 +37,19 @@ in
|
|
|
|
servDM.lomiri.enable # unsure wheather this is using Wayland
|
|
|
|
servDM.lomiri.enable # unsure wheather this is using Wayland
|
|
|
|
servDM.plasma6.enable
|
|
|
|
servDM.plasma6.enable
|
|
|
|
]);
|
|
|
|
]);
|
|
|
|
in
|
|
|
|
})
|
|
|
|
{
|
|
|
|
|
|
|
|
|
|
|
|
(lib.mkIf (config.services.wayland.enable) {
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
# make Steam Input events possible
|
|
|
|
|
|
|
|
programs.steam.extest.enable = lib.mkIf config.programs.steam.enable true;
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
warnings = lib.mkIf (xDM.mate.enable && !xDM.mate.enableWaylandSession) [
|
|
|
|
|
|
|
|
"Wayland & Mate are enabled, but Mate‘s Wayland support is disabled, you should enable services.xserver.displayManager.enableWaylandSession"
|
|
|
|
|
|
|
|
];
|
|
|
|
|
|
|
|
|
|
|
|
# make Steam Input events on Wayland possible
|
|
|
|
})
|
|
|
|
programs.steam.extest.enable = lib.mkIf (config.programs.steam.enable && waylandEnabled) true;
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
}
|
|
|
|
];
|
|
|
|
);
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
}
|
|
|
|
}
|
|
|
|