Changeset 56927 in vbox
- Timestamp:
- Jul 14, 2015 1:48:35 PM (9 years ago)
- Location:
- trunk/src/VBox/Frontends/VirtualBox/src/platform/x11
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/VBox/Frontends/VirtualBox/src/platform/x11/VBoxX11Helper.cpp
r52727 r56927 5 5 6 6 /* 7 * Copyright (C) 2008-201 0Oracle Corporation7 * Copyright (C) 2008-2015 Oracle Corporation 8 8 * 9 9 * This file is part of VirtualBox Open Source Edition (OSE), as … … 33 33 static BOOL gX11DpmsState; 34 34 35 /**36 * Init the screen saver save/restore mechanism.37 */38 35 void X11ScreenSaverSettingsInit() 39 36 { … … 44 41 } 45 42 46 /**47 * Actually this is a big mess. By default the libSDL disables the screen48 * saver during the SDL_InitSubSystem() call and restores the saved settings49 * during the SDL_QuitSubSystem() call. This mechanism can be disabled by50 * setting the environment variable SDL_VIDEO_ALLOW_SCREENSAVER to 1. However,51 * there is a known bug in the Debian libSDL: If this environment variable is52 * set, the screen saver is still disabled but the old state is not restored53 * during SDL_QuitSubSystem()! So the only solution to overcome this problem54 * is to save and restore the state prior and after each of these function55 * calls.56 */57 43 void X11ScreenSaverSettingsSave() 58 44 { 45 /* Actually this is a big mess. By default the libSDL disables the screen saver 46 * during the SDL_InitSubSystem() call and restores the saved settings during 47 * the SDL_QuitSubSystem() call. This mechanism can be disabled by setting the 48 * environment variable SDL_VIDEO_ALLOW_SCREENSAVER to 1. However, there is a 49 * known bug in the Debian libSDL: If this environment variable is set, the 50 * screen saver is still disabled but the old state is not restored during 51 * SDL_QuitSubSystem()! So the only solution to overcome this problem is to 52 * save and restore the state prior and after each of these function calls. */ 53 59 54 int dummy; 60 55 CARD16 dummy2; … … 66 61 } 67 62 68 /**69 * Restore previously saved screen saver settings.70 */71 63 void X11ScreenSaverSettingsRestore() 72 64 { … … 82 74 } 83 75 84 /**85 * Determine if the current Window manager is KWin (KDE)86 */87 76 bool X11IsWindowManagerKWin() 88 77 { -
trunk/src/VBox/Frontends/VirtualBox/src/platform/x11/VBoxX11Helper.h
r55401 r56927 5 5 6 6 /* 7 * Copyright (C) 2006-201 0Oracle Corporation7 * Copyright (C) 2006-2015 Oracle Corporation 8 8 * 9 9 * This file is part of VirtualBox Open Source Edition (OSE), as … … 16 16 */ 17 17 18 #ifndef __ VBoxX11Helpers_h__19 #define __ VBoxX11Helpers_h__18 #ifndef ___VBoxX11Helpers_h___ 19 #define ___VBoxX11Helpers_h___ 20 20 21 /** X11: Inits the screen saver save/restore mechanism. */ 21 22 void X11ScreenSaverSettingsInit(); 23 /** X11: Saves screen saver settings. */ 22 24 void X11ScreenSaverSettingsSave(); 25 /** X11: Restores previously saved screen saver settings. */ 23 26 void X11ScreenSaverSettingsRestore(); 27 28 /** X11: Determines whether current Window Manager is KWin. */ 24 29 bool X11IsWindowManagerKWin(); 25 30 26 #endif 31 #endif /* !___VBoxX11Helpers_h___ */ 27 32
Note:
See TracChangeset
for help on using the changeset viewer.