summaryrefslogtreecommitdiff
authorllornkcor <llornkcor>2005-03-20 09:34:43 (UTC)
committer llornkcor <llornkcor>2005-03-20 09:34:43 (UTC)
commit28bbb05f2a329f2938f2f1cf5ae56831dfa544e4 (patch) (unidiff)
treec7135d32fdad1581e22813516a3dc11eda524f51
parent421ee128d31c51f8530b0e37313ea0086e023237 (diff)
downloadopie-28bbb05f2a329f2938f2f1cf5ae56831dfa544e4.zip
opie-28bbb05f2a329f2938f2f1cf5ae56831dfa544e4.tar.gz
opie-28bbb05f2a329f2938f2f1cf5ae56831dfa544e4.tar.bz2
clean up
Diffstat (more/less context) (ignore whitespace changes)
-rw-r--r--noncore/multimedia/opierec/vumeter.cpp19
1 files changed, 6 insertions, 13 deletions
diff --git a/noncore/multimedia/opierec/vumeter.cpp b/noncore/multimedia/opierec/vumeter.cpp
index 0edc806..c28dbe4 100644
--- a/noncore/multimedia/opierec/vumeter.cpp
+++ b/noncore/multimedia/opierec/vumeter.cpp
@@ -28,23 +28,18 @@ VUMeter::VUMeter(QWidget *parent, const char *name, const int tr)
28 } 28 }
29 29
30 readConf(); 30 readConf();
31 31
32// QColor c;
33// c.setHsv( (x * 255)/w, 255, 255 );// rainbow effect
34// c.setRgb( 255, 0, 255);
35// p.setPen(c);
36
37 //rainbow effect 32 //rainbow effect
38 if( colorScheme = 0 ) { 33 if( colorScheme == 0 ) {
39 for( i = 0; i < para.leds; i++) color[i] = green; 34 for( i = 0; i < para.leds; i++) color[i] = green;
40 color[0] = color[1] = red; 35 color[0] = color[1] = red;
41 color[2] = color[3] = color[4] = color[5] = yellow; 36 color[2] = color[3] = color[4] = color[5] = yellow;
42 } else { 37 } else {
43 int j = para.leds - 4; 38 int j = para.leds - 4;
44 for( i = 0; i < para.leds; i++) { 39 for( i = 0; i < para.leds; i++) {
45 int i16 = (j);// & 15; 40 int i16 = (j);
46 color[i] = QColor(( 15 - i16) * 16, 255, 255, QColor::Hsv); 41 color[i] = QColor(( 15 - i16) * 16, 255, 255, QColor::Hsv);
47 owarn << color[i].name() << oendl; 42// owarn << color[i].name() << oendl;
48 j--; 43 j--;
49 } 44 }
50 } 45 }
@@ -61,7 +56,7 @@ VUMeter::~VUMeter(){
61} 56}
62 57
63void VUMeter::update(){ 58void VUMeter::update(){
64 qWarning("vumeter update"); 59// qWarning("vumeter update");
65 vuTimer->start(para.update, FALSE); 60 vuTimer->start(para.update, FALSE);
66 if (para.onOff) { 61 if (para.onOff) {
67 disconnect(vuTimer, SIGNAL(timeout()), this , SLOT(timeSlot())); 62 disconnect(vuTimer, SIGNAL(timeout()), this , SLOT(timeSlot()));
@@ -222,9 +217,7 @@ void VUMeter::readConf() {
222 para.leds = config.readNumEntry("LEDs", 20); 217 para.leds = config.readNumEntry("LEDs", 20);
223 para.resoFactor = pow(2, para.reso / 6.0); 218 para.resoFactor = pow(2, para.reso / 6.0);
224 219
225 colorScheme = config.readNumEntry("colorScheme", 0); 220 colorScheme = config.readNumEntry("colorScheme", 1);
226// update();
227// dia->updatePara();
228} 221}
229 222
230 223