From 514484e0222834250b73fb8344a7a595778432f1 Mon Sep 17 00:00:00 2001 From: Rom Walton Date: Wed, 22 May 2013 12:00:22 -0400 Subject: [PATCH] client: Remove Display Power Management query for idle detection until a new variant can be found. --- client/hostinfo_unix.cpp | 39 --------------------------------------- 1 file changed, 39 deletions(-) diff --git a/client/hostinfo_unix.cpp b/client/hostinfo_unix.cpp index 00c0b28849..a19c8e952d 100644 --- a/client/hostinfo_unix.cpp +++ b/client/hostinfo_unix.cpp @@ -1832,45 +1832,6 @@ bool xss_idle(long idle_treshold) { idle_time = xssInfo->idle; -#if HAVE_DPMS - int dummy; - CARD16 standby, suspend, off; - CARD16 state; - BOOL onoff; - - if (DPMSQueryExtension(disp, &dummy, &dummy)) { - if (DPMSCapable(disp)) { - DPMSGetTimeouts(disp, &standby, &suspend, &off); - DPMSInfo(disp, &state, &onoff); - - if (onoff) { - switch (state) { - case DPMSModeStandby: - /* this check is a littlebit paranoid, but be sure */ - if (idle_time < (unsigned) (standby * 1000)) { - idle_time += (standby * 1000); - } - break; - case DPMSModeSuspend: - if (idle_time < (unsigned) ((suspend + standby) * 1000)) { - idle_time += ((suspend + standby) * 1000); - } - break; - case DPMSModeOff: - if (idle_time < (unsigned) ((off + suspend + standby) * 1000)) { - idle_time += ((off + suspend + standby) * 1000); - } - break; - case DPMSModeOn: - default: - break; - } - } - - } - } -#endif - // convert from milliseconds to seconds idle_time = idle_time / 1000;