test/common.c
changeset 5521 ef550bdb8c1b
parent 5517 aa339c0dca2d
child 5522 38bd9696f659
equal deleted inserted replaced
5520:09b500e0656d 5521:ef550bdb8c1b
  1038                 if (window) {
  1038                 if (window) {
  1039 					SDL_DestroyWindow(window);
  1039 					SDL_DestroyWindow(window);
  1040 				}
  1040 				}
  1041 			}
  1041 			}
  1042             break;
  1042             break;
       
  1043 
       
  1044         case SDL_WINDOWEVENT_RESIZED:
       
  1045             {
       
  1046                 SDL_Window *window = SDL_GetWindowFromID(event->window.windowID);
       
  1047                 if (!window) {
       
  1048                     break;
       
  1049                 }
       
  1050 
       
  1051                 for (i = 0; i < state->num_windows; ++i) {
       
  1052                     if (state->windows[i] == window) {
       
  1053                         if (state->renderers[i]) {
       
  1054                             SDL_RenderSetViewport(state->renderers[i], NULL);
       
  1055                         }
       
  1056                         break;
       
  1057                     }
       
  1058                 }
       
  1059             }
       
  1060             break;
  1043         }
  1061         }
  1044         break;
  1062         break;
  1045     case SDL_KEYDOWN:
  1063     case SDL_KEYDOWN:
  1046         switch (event->key.keysym.sym) {
  1064         switch (event->key.keysym.sym) {
  1047             /* Add hotkeys here */
  1065             /* Add hotkeys here */