commit
All checks were successful
Rust Checks / checks (push) Successful in 28m37s

This commit is contained in:
raphael 2024-04-01 01:24:55 +02:00
parent 0aaf000c47
commit 285cd28512

View file

@ -28,10 +28,10 @@ pub fn change_scaling(
windows: Query<&Window>,
size: Res<UILayoutSize>,
) {
if !windows.get_single().unwrap().resolution.physical_height() > 0 {
let window = windows.get_single().expect("Main window not found");
if window.resolution.physical_height() == 0 {
return;
};
let window = windows.get_single().expect("Main window not found");
let (a, b) = (
window.resolution.width() / size.0.x,
window.resolution.height() / size.0.y,