diff --git a/modules/windowinfo/Preview.qml b/modules/windowinfo/Preview.qml index 094a9992..6cbb5bc3 100644 --- a/modules/windowinfo/Preview.qml +++ b/modules/windowinfo/Preview.qml @@ -72,7 +72,7 @@ Item { captureSource: root.client?.wayland ?? null live: true - constraintSize.width: parent.height * Math.min(root.screen.width / root.screen.height, root.client?.lastIpcObject.size[0] / root.client?.lastIpcObject.size[1]) + constraintSize.width: root.client ? parent.height * Math.min(root.screen.width / root.screen.height, root.client?.lastIpcObject.size[0] / root.client?.lastIpcObject.size[1]) : parent.height constraintSize.height: parent.height } }