2
0
Эх сурвалжийг харах

Set window size after setting new limits

Otherwise this can fail as the size may not fit
into current limits. This is problematic at least
on X11.
Nikola Bunjevac 2 жил өмнө
parent
commit
d7e9b8af9a
1 өөрчлөгдсөн 1 нэмэгдсэн , 1 устгасан
  1. 1 1
      scene/main/window.cpp

+ 1 - 1
scene/main/window.cpp

@@ -651,9 +651,9 @@ void Window::_update_window_size() {
 			DisplayServer::get_singleton()->window_set_min_size(Size2i(), window_id);
 		}
 
-		DisplayServer::get_singleton()->window_set_size(size, window_id);
 		DisplayServer::get_singleton()->window_set_max_size(max_size_valid ? max_size : Size2i(), window_id);
 		DisplayServer::get_singleton()->window_set_min_size(size_limit, window_id);
+		DisplayServer::get_singleton()->window_set_size(size, window_id);
 	}
 
 	//update the viewport