aboutsummaryrefslogtreecommitdiff
path: root/lumina-wm-INCOMPLETE/SSBaseWidget.cpp
diff options
context:
space:
mode:
authorKen Moore <moorekou@gmail.com>2015-11-03 13:32:35 -0500
committerKen Moore <moorekou@gmail.com>2015-11-03 13:32:35 -0500
commit8417684b84a2ff4bb07c28c89274c045fd4104f8 (patch)
tree754ade19c856f79c00e3fdf3d9c220d62aa87e97 /lumina-wm-INCOMPLETE/SSBaseWidget.cpp
parentAdd all the animations framework for the screensaver side of lumina-wm (with ... (diff)
downloadlumina-8417684b84a2ff4bb07c28c89274c045fd4104f8.tar.gz
lumina-8417684b84a2ff4bb07c28c89274c045fd4104f8.tar.bz2
lumina-8417684b84a2ff4bb07c28c89274c045fd4104f8.zip
Clean up the Screensaver framework a bit more, add a test flag (--test-ss), and fix up the starting of screensavers on all screens simultaneously.
This solidifies the Screensaver plugin framework as completely functional - just need to finish up the lock/unlock screen now.
Diffstat (limited to 'lumina-wm-INCOMPLETE/SSBaseWidget.cpp')
-rw-r--r--lumina-wm-INCOMPLETE/SSBaseWidget.cpp10
1 files changed, 9 insertions, 1 deletions
diff --git a/lumina-wm-INCOMPLETE/SSBaseWidget.cpp b/lumina-wm-INCOMPLETE/SSBaseWidget.cpp
index 3371c5e2..4beb905f 100644
--- a/lumina-wm-INCOMPLETE/SSBaseWidget.cpp
+++ b/lumina-wm-INCOMPLETE/SSBaseWidget.cpp
@@ -7,6 +7,8 @@
#include "SSBaseWidget.h"
+#define DEBUG 1
+
static QStringList validPlugs;
// ========
// PUBLIC
@@ -39,6 +41,7 @@ void SSBaseWidget::startPainting(){
if(valid.isEmpty()){ cplug = "none"; } //no known plugins
else{ cplug = valid[ qrand()%valid.length() ]; } //grab a random plugin
}
+ if(DEBUG){ qDebug() << " - Screen Saver:" << cplug; }
//Now list all the various plugins and start them appropriately
QString style;
if(cplug=="none"){
@@ -50,10 +53,15 @@ void SSBaseWidget::startPainting(){
if(cplug!="none"){
ANIM = BaseAnimGroup::NewAnimation(cplug, this, settings);
connect(ANIM, SIGNAL(finished()), this, SLOT(startPainting()) ); //repeat the plugin as needed
+ ANIM->LoadAnimations();
}
//Now start the animation(s)
if(ANIM!=0){
- if(ANIM->animationCount()>0){ ANIM->start(); }
+ //if(DEBUG){ qDebug() << " - Starting SS Plugin:" << cplug << ANIM->animationCount() << ANIM->duration() << ANIM->loopCount(); }
+ if(ANIM->animationCount()>0){
+ if(DEBUG){ qDebug() << " - Starting SS Plugin:" << cplug << ANIM->animationCount() << ANIM->duration() << ANIM->loopCount(); }
+ ANIM->start();
+ }
}
}
bgstack15