diff options
-rw-r--r-- | lumina-wm-INCOMPLETE/GlobalDefines.h | 1 | ||||
-rw-r--r-- | lumina-wm-INCOMPLETE/LScreenSaver.cpp | 5 | ||||
-rw-r--r-- | lumina-wm-INCOMPLETE/LScreenSaver.h | 5 | ||||
-rw-r--r-- | lumina-wm-INCOMPLETE/SSBaseWidget.cpp | 3 | ||||
-rw-r--r-- | lumina-wm-INCOMPLETE/SSBaseWidget.h | 8 |
5 files changed, 18 insertions, 4 deletions
diff --git a/lumina-wm-INCOMPLETE/GlobalDefines.h b/lumina-wm-INCOMPLETE/GlobalDefines.h index 0ba05f88..b6e6587d 100644 --- a/lumina-wm-INCOMPLETE/GlobalDefines.h +++ b/lumina-wm-INCOMPLETE/GlobalDefines.h @@ -41,6 +41,7 @@ #include <QSettings> #include <QHostInfo> #include <QDesktopWidget> +#include <QStyleOption> // libLumina includes #include <LuminaX11.h> diff --git a/lumina-wm-INCOMPLETE/LScreenSaver.cpp b/lumina-wm-INCOMPLETE/LScreenSaver.cpp index 7b048285..7a2105f8 100644 --- a/lumina-wm-INCOMPLETE/LScreenSaver.cpp +++ b/lumina-wm-INCOMPLETE/LScreenSaver.cpp @@ -8,7 +8,7 @@ #include <QScreen> #include <QApplication> -#define DEBUG 1 +#define DEBUG 0 LScreenSaver::LScreenSaver() : QWidget(0,Qt::BypassWindowManagerHint | Qt::WindowStaysOnTopHint){ starttimer = new QTimer(this); @@ -23,7 +23,8 @@ LScreenSaver::LScreenSaver() : QWidget(0,Qt::BypassWindowManagerHint | Qt::Windo settings = new QSettings("LuminaDE","lumina-screensaver",this); SSRunning = SSLocked = updating = false; this->setObjectName("LSCREENSAVERBASE"); - this->setStyleSheet("LScreenSaver#LSCREENSAVERBASE{ background: black; }"); + this->setStyleSheet("LScreenSaver#LSCREENSAVERBASE{ background: grey; }"); + this->setMouseTracking(true); connect(starttimer, SIGNAL(timeout()), this, SLOT(ShowScreenSaver()) ); connect(locktimer, SIGNAL(timeout()), this, SLOT(LockScreen()) ); connect(hidetimer, SIGNAL(timeout()), this, SLOT(HideLockScreen()) ); diff --git a/lumina-wm-INCOMPLETE/LScreenSaver.h b/lumina-wm-INCOMPLETE/LScreenSaver.h index ba843c18..5119d8b1 100644 --- a/lumina-wm-INCOMPLETE/LScreenSaver.h +++ b/lumina-wm-INCOMPLETE/LScreenSaver.h @@ -49,6 +49,11 @@ signals: void StartingScreenSaver(); void ClosingScreenSaver(); +protected: + void mouseMoveEvent(QMouseEvent*){ + QTimer::singleShot(0,this, SLOT(newInputEvent())); + } + }; #endif
\ No newline at end of file diff --git a/lumina-wm-INCOMPLETE/SSBaseWidget.cpp b/lumina-wm-INCOMPLETE/SSBaseWidget.cpp index 599d71fb..83b82ff8 100644 --- a/lumina-wm-INCOMPLETE/SSBaseWidget.cpp +++ b/lumina-wm-INCOMPLETE/SSBaseWidget.cpp @@ -16,6 +16,7 @@ static QStringList validPlugs; SSBaseWidget::SSBaseWidget(QWidget *parent, QSettings *set) : QWidget(parent){ if(validPlugs.isEmpty()){ validPlugs << "none"; } //add more later settings = set; //needed to pass along for plugins to read any special options/settings + this->setObjectName("LuminaBaseSSWidget"); ANIM = 0; this->setMouseTracking(true); } @@ -54,7 +55,7 @@ void SSBaseWidget::startPainting(){ }else{ style = "background: black;"; } - this->setStyleSheet(style); + this->setStyleSheet("QWidget#LuminaBaseSSWidget{ "+style+"}"); this->repaint(); //If not a stylesheet-based plugin - set it here if(cplug!="none"){ diff --git a/lumina-wm-INCOMPLETE/SSBaseWidget.h b/lumina-wm-INCOMPLETE/SSBaseWidget.h index 1649cdd5..a6574679 100644 --- a/lumina-wm-INCOMPLETE/SSBaseWidget.h +++ b/lumina-wm-INCOMPLETE/SSBaseWidget.h @@ -43,7 +43,13 @@ protected: ev->accept(); emit InputDetected(); } - + void paintEvent(QPaintEvent*){ + QStyleOption opt; + opt.init(this); + QPainter p(this); + style()->drawPrimitive(QStyle::PE_Widget, &opt, &p, this); + } + }; #endif |