diff options
author | Ken Moore <moorekou@gmail.com> | 2020-05-21 10:20:11 -0400 |
---|---|---|
committer | Ken Moore <moorekou@gmail.com> | 2020-05-21 10:21:36 -0400 |
commit | 300ed02b95d52e6e86177c0f23e6211c6e855496 (patch) | |
tree | 64e88a5748acee8e65a55134f8ebdc4abf381957 | |
parent | Merge pull request #729 from smarquespt/master (diff) | |
download | lumina-300ed02b95d52e6e86177c0f23e6211c6e855496.tar.gz lumina-300ed02b95d52e6e86177c0f23e6211c6e855496.tar.bz2 lumina-300ed02b95d52e6e86177c0f23e6211c6e855496.zip |
Ensure the older screensaver system in X11 is also disabled when DPMS is disabled
-rw-r--r-- | src-qt5/core/libLumina/LuminaX11.cpp | 3 | ||||
-rw-r--r-- | src-qt5/core/libLumina/LuminaX11.pri | 2 |
2 files changed, 4 insertions, 1 deletions
diff --git a/src-qt5/core/libLumina/LuminaX11.cpp b/src-qt5/core/libLumina/LuminaX11.cpp index 6a71f629..96f7c17f 100644 --- a/src-qt5/core/libLumina/LuminaX11.cpp +++ b/src-qt5/core/libLumina/LuminaX11.cpp @@ -31,6 +31,7 @@ //XLib includes #include <X11/extensions/Xdamage.h> +#include <X11/Xproto.h> #define DEBUG 0 @@ -188,11 +189,13 @@ void LXCB::SetCurrentWorkspace(int number){ //Display Power Management System (DPMS) // ===== enableDPMS() ===== void LXCB::enableDPMS(){ + XSetScreenSaver( QX11Info::display(), 600, 600, PreferBlanking, DontAllowExposures); //10 minutes - older pre-dpms protocol xcb_dpms_enable(QX11Info::connection()); } // ===== disableDPMS() ===== void LXCB::disableDPMS(){ + XSetScreenSaver( QX11Info::display(), 0, 0, PreferBlanking, DontAllowExposures); //older pre-dpms protocol xcb_dpms_disable(QX11Info::connection()); } diff --git a/src-qt5/core/libLumina/LuminaX11.pri b/src-qt5/core/libLumina/LuminaX11.pri index e22b83ad..163fe50e 100644 --- a/src-qt5/core/libLumina/LuminaX11.pri +++ b/src-qt5/core/libLumina/LuminaX11.pri @@ -1,7 +1,7 @@ QT *= x11extras -LIBS *= -lc -lxcb -lxcb-ewmh -lxcb-icccm -lxcb-image -lxcb-composite -lxcb-damage -lxcb-util -lxcb-dpms -lXdamage +LIBS *= -lc -lxcb -lxcb-ewmh -lxcb-icccm -lxcb-image -lxcb-composite -lxcb-damage -lxcb-util -lxcb-dpms -lXdamage -lX11 #LUtils Files SOURCES *= $${PWD}/LuminaX11.cpp |