only resize output when using wayland backend

surprisingly enough, real hardware complains
Daniel Barlow 2022-07-01 22:09:00 +00:00
parent b04c91c897
commit a8f7448245
1 changed files with 4 additions and 1 deletions

5
rc.fnl
View File

@ -13,11 +13,14 @@
)]
(socket-repl.start repl-socket-name))
(fn resize-wayland-backend [output]
(when (string.find (output:name) "^WL-")
(output:set_mode 360 720 0)))
(kiwmi:on
"output"
(fn [output]
(output:set_mode 360 720 0)
(resize-wayland-backend output)
(let [[width height] (output:size)
r (output:renderer)
kill (texture.from-file r "close-window.png")