Commit 864ad758 authored by Patrice Mandin's avatar Patrice Mandin

Simplify setting window title

--HG--
extra : convert_revision : svn%3Ac70aab31-4412-0410-b14c-859654838e24/trunk%402512
parent abcafc21
...@@ -156,24 +156,12 @@ GEM_PumpEvents(_THIS) ...@@ -156,24 +156,12 @@ GEM_PumpEvents(_THIS)
/* Refresh window name ? */ /* Refresh window name ? */
if (GEM_refresh_name) { if (GEM_refresh_name) {
if (SDL_GetAppState() & SDL_APPACTIVE) { const char *window_name = (SDL_GetAppState() & SDL_APPACTIVE) ?
/* Fullscreen/windowed */ GEM_title_name : GEM_icon_name;
if (GEM_title_name) { if (window_name) {
wind_set(GEM_handle, WF_NAME, wind_set(GEM_handle, WF_NAME,
(short) (((unsigned long) GEM_title_name) >> (short) (((unsigned long) window_name) >> 16),
16), (short) (((unsigned long) window_name) & 0xffff), 0, 0);
(short) (((unsigned long) GEM_title_name) &
0xffff), 0, 0);
}
} else {
/* Iconified */
if (GEM_icon_name) {
wind_set(GEM_handle, WF_NAME,
(short) (((unsigned long) GEM_icon_name) >>
16),
(short) (((unsigned long) GEM_icon_name) &
0xffff), 0, 0);
}
} }
GEM_refresh_name = SDL_FALSE; GEM_refresh_name = SDL_FALSE;
} }
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment