summaryrefslogtreecommitdiff
path: root/noncore/multimedia/opieplayer2/mediaplayer.cpp
authorharlekin <harlekin>2002-08-19 21:11:10 (UTC)
committer harlekin <harlekin>2002-08-19 21:11:10 (UTC)
commit0d336f310b310ba18af70185eed58be6e07c26d8 (patch) (unidiff)
tree4084cce27741e5e3ae1bc309d539b7db2ecc8e99 /noncore/multimedia/opieplayer2/mediaplayer.cpp
parent7f1a7e9b3272f7848423583ea5fc04eb67d97f14 (diff)
downloadopie-0d336f310b310ba18af70185eed58be6e07c26d8.zip
opie-0d336f310b310ba18af70185eed58be6e07c26d8.tar.gz
opie-0d336f310b310ba18af70185eed58be6e07c26d8.tar.bz2
fixes
Diffstat (limited to 'noncore/multimedia/opieplayer2/mediaplayer.cpp') (more/less context) (ignore whitespace changes)
-rw-r--r--noncore/multimedia/opieplayer2/mediaplayer.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/noncore/multimedia/opieplayer2/mediaplayer.cpp b/noncore/multimedia/opieplayer2/mediaplayer.cpp
index 18caaad..0f8242b 100644
--- a/noncore/multimedia/opieplayer2/mediaplayer.cpp
+++ b/noncore/multimedia/opieplayer2/mediaplayer.cpp
@@ -159,50 +159,50 @@ void MediaPlayer::stopChangingVolume() {
159 onScreenDisplayVolume = 0; 159 onScreenDisplayVolume = 0;
160 int w=0; 160 int w=0;
161 int h=0; 161 int h=0;
162 if( !xineControl->hasVideo()) { 162 if( !xineControl->hasVideo()) {
163 w = audioUI->width(); 163 w = audioUI->width();
164 h = audioUI->height(); 164 h = audioUI->height();
165 audioUI->repaint( (w - 200) / 2, h - yoff, 200 + 9, 70, FALSE ); 165 audioUI->repaint( (w - 200) / 2, h - yoff, 200 + 9, 70, FALSE );
166 } else { 166 } else {
167 w = videoUI->width(); 167 w = videoUI->width();
168 h = videoUI->height(); 168 h = videoUI->height();
169 videoUI->repaint( (w - 200) / 2, h - yoff, 200 + 9, 70, FALSE ); 169 videoUI->repaint( (w - 200) / 2, h - yoff, 200 + 9, 70, FALSE );
170 } 170 }
171} 171}
172 172
173 173
174void MediaPlayer::timerEvent( QTimerEvent * ) { 174void MediaPlayer::timerEvent( QTimerEvent * ) {
175 if ( volumeDirection == +1 ) { 175 if ( volumeDirection == +1 ) {
176 volControl->incVol(2); 176 volControl->incVol(2);
177 } else if ( volumeDirection == -1 ) { 177 } else if ( volumeDirection == -1 ) {
178 volControl->decVol(2); 178 volControl->decVol(2);
179 } 179 }
180 180
181 181
182 // TODO FIXME 182 // TODO FIXME
183 unsigned int v; 183 unsigned int v= 0;
184 v = volControl->getVolume(); 184 v = volControl->volume();
185 v = v / 10; 185 v = v / 10;
186 186
187 if ( drawnOnScreenDisplay && onScreenDisplayVolume == v ) { 187 if ( drawnOnScreenDisplay && onScreenDisplayVolume == v ) {
188 return; 188 return;
189 } 189 }
190 190
191 int w=0; int h=0; 191 int w=0; int h=0;
192 if( !xineControl->hasVideo()) { 192 if( !xineControl->hasVideo()) {
193 w = audioUI->width(); 193 w = audioUI->width();
194 h = audioUI->height(); 194 h = audioUI->height();
195 195
196 if ( drawnOnScreenDisplay ) { 196 if ( drawnOnScreenDisplay ) {
197 if ( onScreenDisplayVolume > v ) { 197 if ( onScreenDisplayVolume > v ) {
198 audioUI->repaint( (w - 200) / 2 + v * 20 + 0, h - yoff + 40, (onScreenDisplayVolume - v) * 20 + 9, 30, FALSE ); 198 audioUI->repaint( (w - 200) / 2 + v * 20 + 0, h - yoff + 40, (onScreenDisplayVolume - v) * 20 + 9, 30, FALSE );
199 } 199 }
200 } 200 }
201 drawnOnScreenDisplay = TRUE; 201 drawnOnScreenDisplay = TRUE;
202 onScreenDisplayVolume = v; 202 onScreenDisplayVolume = v;
203 QPainter p( audioUI ); 203 QPainter p( audioUI );
204 p.setPen( QColor( 0x10, 0xD0, 0x10 ) ); 204 p.setPen( QColor( 0x10, 0xD0, 0x10 ) );
205 p.setBrush( QColor( 0x10, 0xD0, 0x10 ) ); 205 p.setBrush( QColor( 0x10, 0xD0, 0x10 ) );
206 206
207 QFont f; 207 QFont f;
208 f.setPixelSize( 20 ); 208 f.setPixelSize( 20 );