Mercurial > sdl-ios-xcode
comparison src/events/SDL_windowevents.c @ 3502:98a819296cdc
Whenever a window becomes fullscreen, shown, unminimized, and has input focus it will change the display to the corresponding fullscreen video mode.
If it loses any of those properties the desktop mode will be restored.
author | Sam Lantinga <slouken@libsdl.org> |
---|---|
date | Tue, 01 Dec 2009 08:56:12 +0000 |
parents | 91a7e08cd238 |
children | 41cd18e05965 |
comparison
equal
deleted
inserted
replaced
3501:467e67d301f3 | 3502:98a819296cdc |
---|---|
84 case SDL_WINDOWEVENT_MINIMIZED: | 84 case SDL_WINDOWEVENT_MINIMIZED: |
85 if (window->flags & SDL_WINDOW_MINIMIZED) { | 85 if (window->flags & SDL_WINDOW_MINIMIZED) { |
86 return 0; | 86 return 0; |
87 } | 87 } |
88 window->flags |= SDL_WINDOW_MINIMIZED; | 88 window->flags |= SDL_WINDOW_MINIMIZED; |
89 SDL_OnWindowMinimized(window); | |
89 break; | 90 break; |
90 case SDL_WINDOWEVENT_MAXIMIZED: | 91 case SDL_WINDOWEVENT_MAXIMIZED: |
91 if (window->flags & SDL_WINDOW_MAXIMIZED) { | 92 if (window->flags & SDL_WINDOW_MAXIMIZED) { |
92 return 0; | 93 return 0; |
93 } | 94 } |
96 case SDL_WINDOWEVENT_RESTORED: | 97 case SDL_WINDOWEVENT_RESTORED: |
97 if (!(window->flags & (SDL_WINDOW_MINIMIZED | SDL_WINDOW_MAXIMIZED))) { | 98 if (!(window->flags & (SDL_WINDOW_MINIMIZED | SDL_WINDOW_MAXIMIZED))) { |
98 return 0; | 99 return 0; |
99 } | 100 } |
100 window->flags &= ~(SDL_WINDOW_MINIMIZED | SDL_WINDOW_MAXIMIZED); | 101 window->flags &= ~(SDL_WINDOW_MINIMIZED | SDL_WINDOW_MAXIMIZED); |
102 SDL_OnWindowRestored(window); | |
101 break; | 103 break; |
102 case SDL_WINDOWEVENT_ENTER: | 104 case SDL_WINDOWEVENT_ENTER: |
103 if (window->flags & SDL_WINDOW_MOUSE_FOCUS) { | 105 if (window->flags & SDL_WINDOW_MOUSE_FOCUS) { |
104 return 0; | 106 return 0; |
105 } | 107 } |