src/events/SDL_windowevents.c
changeset 5398 83816c8a2b58
parent 5383 40c76519000e
child 5524 b7f53a566ef1
equal deleted inserted replaced
5397:88ff1f463134 5398:83816c8a2b58
    87     case SDL_WINDOWEVENT_MOVED:
    87     case SDL_WINDOWEVENT_MOVED:
    88         if (SDL_WINDOWPOS_ISUNDEFINED(data1) ||
    88         if (SDL_WINDOWPOS_ISUNDEFINED(data1) ||
    89             SDL_WINDOWPOS_ISUNDEFINED(data2)) {
    89             SDL_WINDOWPOS_ISUNDEFINED(data2)) {
    90             return 0;
    90             return 0;
    91         }
    91         }
       
    92         if (!(window->flags & SDL_WINDOW_FULLSCREEN)) {
       
    93             window->windowed.x = data1;
       
    94             window->windowed.y = data2;
       
    95         }
    92         if (data1 == window->x && data2 == window->y) {
    96         if (data1 == window->x && data2 == window->y) {
    93             return 0;
    97             return 0;
    94         }
    98         }
    95         window->x = data1;
    99         window->x = data1;
    96         window->y = data2;
   100         window->y = data2;
    97         break;
   101         break;
    98     case SDL_WINDOWEVENT_RESIZED:
   102     case SDL_WINDOWEVENT_RESIZED:
       
   103         if (!(window->flags & SDL_WINDOW_FULLSCREEN)) {
       
   104             window->windowed.w = data1;
       
   105             window->windowed.h = data2;
       
   106         }
    99         if (data1 == window->w && data2 == window->h) {
   107         if (data1 == window->w && data2 == window->h) {
   100             return 0;
   108             return 0;
   101         }
   109         }
   102         window->w = data1;
   110         window->w = data1;
   103         window->h = data2;
   111         window->h = data2;