diff options
author | Ken Moore <moorekou@gmail.com> | 2020-05-06 16:03:47 -0400 |
---|---|---|
committer | Ken Moore <moorekou@gmail.com> | 2020-05-06 16:03:47 -0400 |
commit | 82901d366a7c6bfa4d4b7510f292abccc58b33d6 (patch) | |
tree | a5b53da08e19e4225f60dc7627471730e3e86bfd /src-qt5/core/lumina-desktop/src-screensaver/LScreenSaver.cpp | |
parent | Convert to QElapsedTimer for a debugging timer. (diff) | |
download | lumina-82901d366a7c6bfa4d4b7510f292abccc58b33d6.tar.gz lumina-82901d366a7c6bfa4d4b7510f292abccc58b33d6.tar.bz2 lumina-82901d366a7c6bfa4d4b7510f292abccc58b33d6.zip |
Ensure that the xorg DPMS system is only enabled when the screensaver comes on.
It does not seem to have the same input/activity checks that the screensaver uses
Diffstat (limited to 'src-qt5/core/lumina-desktop/src-screensaver/LScreenSaver.cpp')
-rw-r--r-- | src-qt5/core/lumina-desktop/src-screensaver/LScreenSaver.cpp | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/src-qt5/core/lumina-desktop/src-screensaver/LScreenSaver.cpp b/src-qt5/core/lumina-desktop/src-screensaver/LScreenSaver.cpp index 850f14b4..6ccd8420 100644 --- a/src-qt5/core/lumina-desktop/src-screensaver/LScreenSaver.cpp +++ b/src-qt5/core/lumina-desktop/src-screensaver/LScreenSaver.cpp @@ -66,6 +66,7 @@ void LScreenSaver::UpdateTimers(){ // =========== void LScreenSaver::start(){ reloadSettings(); //setup all the initial time frames + LSession::handle()->XCB->disableDPMS(); //disable this initially - this only gets turned on when the screensaver activates starttimer->start(); checkTimer->start(); } @@ -128,6 +129,7 @@ void LScreenSaver::ShowScreenSaver(){ //QApplication::setOverrideCursor(QCursor::BlankCursor); SSRunning = true; updating = true; + LSession::handle()->XCB->enableDPMS(); //Now remove any current Base widgets (prevent any lingering painting between sessions) for(int i=0; i<BASES.length(); i++){ if(DEBUG){ qDebug() << " - Removing SS Base"; } @@ -183,6 +185,7 @@ void LScreenSaver::HideScreenSaver(){ //QApplication::restoreOverrideCursor(); if(DEBUG){ qDebug() << "Hiding Screen Saver:" << QDateTime::currentDateTime().toString(); } SSRunning = false; + LSession::handle()->XCB->disableDPMS(); //if(cBright>0){ LOS::setScreenBrightness(cBright); } //return to current brightness this->releaseKeyboard(); if(!SSLocked){ |