comparison src/video/x11/SDL_x11video.c @ 449:8a687496061f

Added an environment variable SDL_VIDEO_X11_WMCLASS
author Sam Lantinga <slouken@libsdl.org>
date Mon, 19 Aug 2002 03:40:44 +0000
parents 406b12a17b15
children ffa4ca907c67
comparison
equal deleted inserted replaced
448:323c766f5a46 449:8a687496061f
348 /* Set the class hints so we can get an icon (AfterStep) */ 348 /* Set the class hints so we can get an icon (AfterStep) */
349 { 349 {
350 XClassHint *classhints; 350 XClassHint *classhints;
351 classhints = XAllocClassHint(); 351 classhints = XAllocClassHint();
352 if(classhints != NULL) { 352 if(classhints != NULL) {
353 classhints->res_name = "SDL_App"; 353 char *classname = getenv("SDL_VIDEO_X11_WMCLASS");
354 classhints->res_class = "SDL_App"; 354 if ( ! classname ) {
355 classname = "SDL_App";
356 }
357 classhints->res_name = classname;
358 classhints->res_class = classname;
355 XSetClassHint(SDL_Display, WMwindow, classhints); 359 XSetClassHint(SDL_Display, WMwindow, classhints);
356 XFree(classhints); 360 XFree(classhints);
357 } 361 }
358 } 362 }
359 363