summaryrefslogtreecommitdiff
path: root/src/client.cpp
diff options
context:
space:
mode:
authorAndrei Karas <akaras@inbox.ru>2012-10-20 21:41:08 +0300
committerAndrei Karas <akaras@inbox.ru>2012-10-20 21:41:08 +0300
commitcf1744f779b38bdc3e5119ab831037ff3228a898 (patch)
treeace3e1d03b55b0a861d3150e36c8fafda9fc2994 /src/client.cpp
parentd9994f114b1febf4c075d77c0fb3e7a44e510e20 (diff)
downloadplus-cf1744f779b38bdc3e5119ab831037ff3228a898.tar.gz
plus-cf1744f779b38bdc3e5119ab831037ff3228a898.tar.bz2
plus-cf1744f779b38bdc3e5119ab831037ff3228a898.tar.xz
plus-cf1744f779b38bdc3e5119ab831037ff3228a898.zip
Add option to allow screensaver. (by default screensaver disabled)
Diffstat (limited to 'src/client.cpp')
-rw-r--r--src/client.cpp5
1 files changed, 5 insertions, 0 deletions
diff --git a/src/client.cpp b/src/client.cpp
index 7168f0cec..5dd417670 100644
--- a/src/client.cpp
+++ b/src/client.cpp
@@ -355,6 +355,11 @@ void Client::gameInit()
putenv("SDL_VIDEO_CENTERED=0");
#endif
+ if (config.getBoolValue("allowscreensaver"))
+ putenv("SDL_VIDEO_ALLOW_SCREENSAVER=1");
+ else
+ putenv("SDL_VIDEO_ALLOW_SCREENSAVER=0");
+
chatLogger = new ChatLogger;
if (mOptions.chatLogDir == "")
chatLogger->setBaseLogDir(mLocalDataDir + std::string("/logs/"));