mirror of
https://github.com/nickolaj-jepsen/nixos.git
synced 2026-01-22 16:16:50 +01:00
fix: add refreshRateNiri
This commit is contained in:
parent
a33c6008d1
commit
ad9440eb6a
3 changed files with 13 additions and 6 deletions
|
|
@ -296,15 +296,13 @@ in {
|
|||
};
|
||||
|
||||
outputs = lib.mkIf (config.monitors != []) (
|
||||
lib.listToAttrs (map (monitor: let
|
||||
refreshRateFloat = lib.mkIf (monitor.refreshRate != null) (builtins.fromJSON "${builtins.toString monitor.refreshRate}.0");
|
||||
in {
|
||||
lib.listToAttrs (map (monitor: {
|
||||
inherit (monitor) name;
|
||||
value = {
|
||||
inherit (monitor) position;
|
||||
mode = {
|
||||
inherit (monitor.resolution) width height;
|
||||
refresh = refreshRateFloat;
|
||||
refresh = monitor.refreshRateNiri or null;
|
||||
};
|
||||
focus-at-startup = monitor.name == primaryMonitorName;
|
||||
transform.rotation =
|
||||
|
|
|
|||
|
|
@ -28,6 +28,12 @@
|
|||
example = 60;
|
||||
};
|
||||
|
||||
refreshRateNiri = lib.mkOption {
|
||||
type = lib.types.nullOr lib.types.float;
|
||||
default = null;
|
||||
example = 60.0;
|
||||
};
|
||||
|
||||
position.x = lib.mkOption {
|
||||
type = lib.types.int;
|
||||
default = 0;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue