fix(displays): keep refresh rate when changing scale

This commit is contained in:
Michael Aaron Murphy 2025-02-17 19:05:37 +01:00 committed by Michael Murphy
parent b4fb20f235
commit dab4bfb828

View file

@ -1049,9 +1049,13 @@ impl Page {
return Task::none();
};
let rate = current.refresh_rate;
task.arg("mode")
.arg("--scale")
.arg(format!("{}.{:02}", scale / 100, scale % 100))
.arg("--refresh")
.arg(format!("{}.{:03}", rate / 1000, rate % 1000))
.arg(name)
.arg(itoa::Buffer::new().format(current.size.0))
.arg(itoa::Buffer::new().format(current.size.1));