comparison src/video/win32/SDL_win32events.c @ 3025:54fac87e1f34

Added an API to enable/disable the screen saver. The screensaver is disabled by default when using SDL 1.2 compatibility. Use the new XScreenSaver extension, removed unused DPMS extension.
author Sam Lantinga <slouken@libsdl.org>
date Mon, 12 Jan 2009 06:19:05 +0000
parents 502adab079a4
children 77c3e67f0740
comparison
equal deleted inserted replaced
3024:1a08749aebce 3025:54fac87e1f34
576 case WM_SYSCOMMAND: 576 case WM_SYSCOMMAND:
577 { 577 {
578 /* Don't start the screensaver or blank the monitor in fullscreen apps */ 578 /* Don't start the screensaver or blank the monitor in fullscreen apps */
579 if ((wParam & 0xFFF0) == SC_SCREENSAVE || 579 if ((wParam & 0xFFF0) == SC_SCREENSAVE ||
580 (wParam & 0xFFF0) == SC_MONITORPOWER) { 580 (wParam & 0xFFF0) == SC_MONITORPOWER) {
581 if (SDL_GetWindowFlags(data->windowID) & 581 SDL_VideoData *videodata = data->videodata;
582 SDL_WINDOW_FULLSCREEN) { 582 if (videodata->suspend_screensaver) {
583 return (0); 583 return (0);
584 } 584 }
585 } 585 }
586 } 586 }
587 break; 587 break;