Mercurial > sdl-ios-xcode
changeset 922:7b920743ce57
Correctly set window size if resized or maximized
author | Patrice Mandin <patmandin@gmail.com> |
---|---|
date | Thu, 05 Aug 2004 19:40:23 +0000 |
parents | 6126849e59a6 |
children | 2748679027ff |
files | src/video/gem/SDL_gemevents.c |
diffstat | 1 files changed, 5 insertions(+), 2 deletions(-) [+] |
line wrap: on
line diff
--- a/src/video/gem/SDL_gemevents.c Thu Aug 05 19:37:45 2004 +0000 +++ b/src/video/gem/SDL_gemevents.c Thu Aug 05 19:40:23 2004 +0000 @@ -193,6 +193,7 @@ static int do_messages(_THIS, short *message) { int quit, posted; + short x2,y2,w2,h2; quit=0; switch (message[0]) { @@ -240,7 +241,8 @@ case WM_SIZED: wind_set (message[3], WF_CURRXYWH, message[4], message[5], message[6], message[7]); GEM_win_fulled = SDL_FALSE; /* Cancel maximized flag */ - SDL_PrivateResize(message[6], message[7]); + wind_get (message[3], WF_WORKXYWH, &x2, &y2, &w2, &h2); + SDL_PrivateResize(w2, h2); break; case WM_FULLED: { @@ -257,7 +259,8 @@ GEM_win_fulled = SDL_TRUE; } wind_set (message[3], WF_CURRXYWH, x, y, w, h); - SDL_PrivateResize(w, h); + wind_get (message[3], WF_WORKXYWH, &x2, &y2, &w2, &h2); + SDL_PrivateResize(w2, h2); } break; case WM_BOTTOMED: