src/video/SDL_video.c
changeset 7792 b8d4be87970a
parent 7753 e4c38f17bfad
child 7853 4861edda71d1
     1.1 --- a/src/video/SDL_video.c	Sun Oct 06 20:39:23 2013 -0700
     1.2 +++ b/src/video/SDL_video.c	Mon Oct 07 14:16:38 2013 -0700
     1.3 @@ -1551,14 +1551,21 @@
     1.4          }
     1.5      }
     1.6  
     1.7 -    if (!SDL_WINDOWPOS_ISUNDEFINED(x)) {
     1.8 -        window->x = x;
     1.9 -    }
    1.10 -    if (!SDL_WINDOWPOS_ISUNDEFINED(y)) {
    1.11 -        window->y = y;
    1.12 -    }
    1.13 -
    1.14 -    if (!(window->flags & SDL_WINDOW_FULLSCREEN)) {
    1.15 +    if ((window->flags & SDL_WINDOW_FULLSCREEN)) {
    1.16 +        if (!SDL_WINDOWPOS_ISUNDEFINED(x)) {
    1.17 +            window->windowed.x = x;
    1.18 +        }
    1.19 +        if (!SDL_WINDOWPOS_ISUNDEFINED(y)) {
    1.20 +            window->windowed.y = y;
    1.21 +        }
    1.22 +    } else {
    1.23 +        if (!SDL_WINDOWPOS_ISUNDEFINED(x)) {
    1.24 +            window->x = x;
    1.25 +        }
    1.26 +        if (!SDL_WINDOWPOS_ISUNDEFINED(y)) {
    1.27 +            window->y = y;
    1.28 +        }
    1.29 +
    1.30          if (_this->SetWindowPosition) {
    1.31              _this->SetWindowPosition(_this, window);
    1.32          }