mirror of
https://github.com/libsdl-org/SDL.git
synced 2026-02-08 04:47:12 +00:00
x11: Use the floating size for the constraints on non-resizable windows
Otherwise, the window manager can think that the window is larger than it is and try to reposition it.
This commit is contained in:
committed by
Sam Lantinga
parent
384e5486bc
commit
63c164f778
@@ -668,8 +668,8 @@ int X11_CreateWindow(SDL_VideoDevice *_this, SDL_Window *window, SDL_PropertiesI
|
||||
/* Setup the normal size hints */
|
||||
sizehints->flags = 0;
|
||||
if (!(window->flags & SDL_WINDOW_RESIZABLE)) {
|
||||
sizehints->min_width = sizehints->max_width = window->w;
|
||||
sizehints->min_height = sizehints->max_height = window->h;
|
||||
sizehints->min_width = sizehints->max_width = window->floating.w;
|
||||
sizehints->min_height = sizehints->max_height = window->floating.h;
|
||||
sizehints->flags |= (PMaxSize | PMinSize);
|
||||
}
|
||||
if (!undefined_position) {
|
||||
|
||||
Reference in New Issue
Block a user