This commit is contained in:
Melody Madeline Nosurname 2025-03-26 07:48:53 +00:00 committed by GitHub
commit 90f89b3ae9
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -500,13 +500,16 @@ void EventThread::process(RGSSThreadData &rtData)
rtData.rqWindowAdjust.clear();
break;
case REQUEST_WINCENTER :
case REQUEST_WINCENTER : {
rc = SDL_GetDesktopDisplayMode(SDL_GetWindowDisplayIndex(win), &dm);
SDL_Rect rect;
SDL_GetDisplayUsableBounds(SDL_GetWindowDisplayIndex(win), &rect);
if (!rc)
SDL_SetWindowPosition(win,
(dm.w / 2) - (winW / 2),
(dm.h / 2) - (winH / 2));
rect.x + (dm.w / 2) - (winW / 2),
rect.y + (dm.h / 2) - (winH / 2));
rtData.rqWindowAdjust.clear();
}
break;
case REQUEST_WINRENAME :