comparison src/video/x11/SDL_x11wm.c @ 3872:be84332e761e SDL-1.2

Fixed bug #278 Added the GFX_Display to the wminfo structure, contributed by Eric
author Sam Lantinga <slouken@libsdl.org>
date Sun, 24 Sep 2006 00:08:28 +0000
parents b5a4ac87b98c
children 1a327643e741
comparison
equal deleted inserted replaced
3871:4d11f2ae7582 3872:be84332e761e
396 /* Make sure any X11 transactions are completed */ 396 /* Make sure any X11 transactions are completed */
397 SDL_VideoDevice *this = current_video; 397 SDL_VideoDevice *this = current_video;
398 XSync(SDL_Display, False); 398 XSync(SDL_Display, False);
399 SDL_Unlock_EventThread(); 399 SDL_Unlock_EventThread();
400 } 400 }
401
402 #include <stdio.h>
401 int X11_GetWMInfo(_THIS, SDL_SysWMinfo *info) 403 int X11_GetWMInfo(_THIS, SDL_SysWMinfo *info)
402 { 404 {
403 if ( info->version.major <= SDL_MAJOR_VERSION ) { 405 if ( info->version.major <= SDL_MAJOR_VERSION ) {
404 info->subsystem = SDL_SYSWM_X11; 406 info->subsystem = SDL_SYSWM_X11;
405 info->info.x11.display = SDL_Display; 407 info->info.x11.display = SDL_Display;
408 info->version.minor, 410 info->version.minor,
409 info->version.patch) >= 1002 ) { 411 info->version.patch) >= 1002 ) {
410 info->info.x11.fswindow = FSwindow; 412 info->info.x11.fswindow = FSwindow;
411 info->info.x11.wmwindow = WMwindow; 413 info->info.x11.wmwindow = WMwindow;
412 } 414 }
415
416
417 if ( SDL_VERSIONNUM(info->version.major,
418 info->version.minor,
419 info->version.patch) >= 1212 ) {
420 info->info.x11.gfxdisplay = GFX_Display;
421 }
422
413 info->info.x11.lock_func = lock_display; 423 info->info.x11.lock_func = lock_display;
414 info->info.x11.unlock_func = unlock_display; 424 info->info.x11.unlock_func = unlock_display;
415 return(1); 425 return(1);
416 } else { 426 } else {
417 SDL_SetError("Application not compiled with SDL %d.%d\n", 427 SDL_SetError("Application not compiled with SDL %d.%d\n",