mirror of
https://github.com/libsdl-org/SDL.git
synced 2026-01-08 14:23:22 +00:00
x11: SDL_SetWindowPosition on an unmapped window will do the actual move later.
Fixes https://github.com/libsdl-org/sdl2-compat/issues/303
This commit is contained in:
@@ -1065,8 +1065,12 @@ void X11_UpdateWindowPosition(SDL_Window *window, bool use_current_position)
|
||||
&data->expected.x, &data->expected.y);
|
||||
|
||||
// Attempt to move the window
|
||||
data->pending_operation |= X11_PENDING_OP_MOVE;
|
||||
X11_XMoveWindow(display, data->xwindow, data->expected.x, data->expected.y);
|
||||
if (window->flags & SDL_WINDOW_HIDDEN) {
|
||||
window->internal->pending_position = true;
|
||||
} else {
|
||||
data->pending_operation |= X11_PENDING_OP_MOVE;
|
||||
X11_XMoveWindow(display, data->xwindow, data->expected.x, data->expected.y);
|
||||
}
|
||||
}
|
||||
|
||||
bool X11_SetWindowPosition(SDL_VideoDevice *_this, SDL_Window *window)
|
||||
|
||||
Reference in New Issue
Block a user