[prev in list] [next in list] [prev in thread] [next in thread]
List: kde-commits
Subject: KDE/kdebase/workspace/krunner/screensaver
From: Luboš Luňák <l.lunak () kde ! org>
Date: 2009-01-26 15:13:14
Message-ID: 1232982794.536908.9830.nullmailer () svn ! kde ! org
[Download RAW message or body]
SVN commit 916961 by lunakl:
When DPMS-dependent, also check whether all 3 timeouts for saving states are 0,
as this way DPMS can be disabled too, even though it's globally "enabled".
Fixes OOo presentation mode.
M +6 -1 xautolock.cpp
--- trunk/KDE/kdebase/workspace/krunner/screensaver/xautolock.cpp #916960:916961
@@ -228,7 +228,9 @@
#ifdef HAVE_DPMS
BOOL on;
CARD16 state;
+ CARD16 timeout1, timeout2, timeout3;
DPMSInfo( QX11Info::display(), &state, &on );
+ DPMSGetTimeouts( QX11Info::display(), &timeout1, &timeout2, &timeout3 );
// kDebug() << "DPMSInfo " << state << on;
// If DPMS is active, it makes XScreenSaverQueryInfo() report idle time
@@ -237,7 +239,10 @@
// this could prevent locking from working.
if(state == DPMSModeStandby || state == DPMSModeSuspend || state == DPMSModeOff)
activate = true;
- if(!on && mDPMS) {
+ // If we are DPMS-dependent and either DPMS is turned off completely or all
+ // three DPMS modes are turned off, don't activate (apps use this to turn off
+ // screensavers).
+ if(mDPMS && (!on || (timeout1 == 0 && timeout2 == 0 && timeout3 == 0 ))) {
activate = false;
resetTrigger();
}
[prev in list] [next in list] [prev in thread] [next in thread]
Configure |
About |
News |
Add a list |
Sponsored by KoreLogic