Diffstat (limited to 'noncore/multimedia/opieplayer2/mediaplayer.cpp') (more/less context) (ignore whitespace changes)
-rw-r--r-- | noncore/multimedia/opieplayer2/mediaplayer.cpp | 79 |
1 files changed, 46 insertions, 33 deletions
diff --git a/noncore/multimedia/opieplayer2/mediaplayer.cpp b/noncore/multimedia/opieplayer2/mediaplayer.cpp index 553e3c1..8da7f73 100644 --- a/noncore/multimedia/opieplayer2/mediaplayer.cpp +++ b/noncore/multimedia/opieplayer2/mediaplayer.cpp | |||
@@ -15,49 +15,49 @@ | |||
15 | #include "audiowidget.h" | 15 | #include "audiowidget.h" |
16 | #include "videowidget.h" | 16 | #include "videowidget.h" |
17 | #include "volumecontrol.h" | 17 | #include "volumecontrol.h" |
18 | 18 | ||
19 | #include "mediaplayerstate.h" | 19 | #include "mediaplayerstate.h" |
20 | 20 | ||
21 | // for setBacklight() | 21 | // for setBacklight() |
22 | #include <linux/fb.h> | 22 | #include <linux/fb.h> |
23 | #include <sys/file.h> | 23 | #include <sys/file.h> |
24 | #include <sys/ioctl.h> | 24 | #include <sys/ioctl.h> |
25 | 25 | ||
26 | 26 | ||
27 | extern AudioWidget *audioUI; | 27 | extern AudioWidget *audioUI; |
28 | extern VideoWidget *videoUI; | 28 | extern VideoWidget *videoUI; |
29 | extern PlayListWidget *playList; | 29 | extern PlayListWidget *playList; |
30 | extern MediaPlayerState *mediaPlayerState; | 30 | extern MediaPlayerState *mediaPlayerState; |
31 | 31 | ||
32 | 32 | ||
33 | #define FBIOBLANK 0x4611 | 33 | #define FBIOBLANK 0x4611 |
34 | 34 | ||
35 | MediaPlayer::MediaPlayer( QObject *parent, const char *name ) | 35 | MediaPlayer::MediaPlayer( QObject *parent, const char *name ) |
36 | : QObject( parent, name ), volumeDirection( 0 ), currentFile( NULL ) { | 36 | : QObject( parent, name ), volumeDirection( 0 ), currentFile( NULL ) { |
37 | 37 | ||
38 | playList->setCaption(tr("OpiePlayer: Initializating")); | 38 | playList->setCaption(tr("OpiePlayer: Initializating")); |
39 | 39 | ||
40 | qApp->processEvents(); | 40 | qApp->processEvents(); |
41 | // QPEApplication::grabKeyboard(); // EVIL | 41 | // QPEApplication::grabKeyboard(); // EVIL |
42 | connect( qApp,SIGNAL( aboutToQuit()),SLOT( cleanUp()) ); | 42 | connect( qApp,SIGNAL( aboutToQuit()),SLOT( cleanUp()) ); |
43 | 43 | ||
44 | connect( mediaPlayerState, SIGNAL( playingToggled( bool ) ), this, SLOT( setPlaying( bool ) ) ); | 44 | connect( mediaPlayerState, SIGNAL( playingToggled( bool ) ), this, SLOT( setPlaying( bool ) ) ); |
45 | 45 | ||
46 | connect( mediaPlayerState, SIGNAL( pausedToggled( bool ) ), this, SLOT( pauseCheck( bool ) ) ); | 46 | connect( mediaPlayerState, SIGNAL( pausedToggled( bool ) ), this, SLOT( pauseCheck( bool ) ) ); |
47 | 47 | ||
48 | connect( mediaPlayerState, SIGNAL( next() ), this, SLOT( next() ) ); | 48 | connect( mediaPlayerState, SIGNAL( next() ), this, SLOT( next() ) ); |
49 | connect( mediaPlayerState, SIGNAL( prev() ), this, SLOT( prev() ) ); | 49 | connect( mediaPlayerState, SIGNAL( prev() ), this, SLOT( prev() ) ); |
50 | connect( mediaPlayerState, SIGNAL( blankToggled( bool ) ), this, SLOT ( blank( bool ) ) ); | 50 | connect( mediaPlayerState, SIGNAL( blankToggled( bool ) ), this, SLOT ( blank( bool ) ) ); |
51 | 51 | ||
52 | connect( audioUI, SIGNAL( moreClicked() ), this, SLOT( startIncreasingVolume() ) ); | 52 | connect( audioUI, SIGNAL( moreClicked() ), this, SLOT( startIncreasingVolume() ) ); |
53 | connect( audioUI, SIGNAL( lessClicked() ), this, SLOT( startDecreasingVolume() ) ); | 53 | connect( audioUI, SIGNAL( lessClicked() ), this, SLOT( startDecreasingVolume() ) ); |
54 | connect( audioUI, SIGNAL( moreReleased() ), this, SLOT( stopChangingVolume() ) ); | 54 | connect( audioUI, SIGNAL( moreReleased() ), this, SLOT( stopChangingVolume() ) ); |
55 | connect( audioUI, SIGNAL( lessReleased() ), this, SLOT( stopChangingVolume() ) ); | 55 | connect( audioUI, SIGNAL( lessReleased() ), this, SLOT( stopChangingVolume() ) ); |
56 | 56 | ||
57 | connect( videoUI, SIGNAL( moreClicked() ), this, SLOT( startIncreasingVolume() ) ); | 57 | connect( videoUI, SIGNAL( moreClicked() ), this, SLOT( startIncreasingVolume() ) ); |
58 | connect( videoUI, SIGNAL( lessClicked() ), this, SLOT( startDecreasingVolume() ) ); | 58 | connect( videoUI, SIGNAL( lessClicked() ), this, SLOT( startDecreasingVolume() ) ); |
59 | connect( videoUI, SIGNAL( moreReleased() ), this, SLOT( stopChangingVolume() ) ); | 59 | connect( videoUI, SIGNAL( moreReleased() ), this, SLOT( stopChangingVolume() ) ); |
60 | connect( videoUI, SIGNAL( lessReleased() ), this, SLOT( stopChangingVolume() ) ); | 60 | connect( videoUI, SIGNAL( lessReleased() ), this, SLOT( stopChangingVolume() ) ); |
61 | 61 | ||
62 | volControl = new VolumeControl; | 62 | volControl = new VolumeControl; |
63 | xineControl = new XineControl(); | 63 | xineControl = new XineControl(); |
@@ -79,79 +79,92 @@ void MediaPlayer::play() { | |||
79 | mediaPlayerState->setPlaying( FALSE ); | 79 | mediaPlayerState->setPlaying( FALSE ); |
80 | mediaPlayerState->setPlaying( TRUE ); | 80 | mediaPlayerState->setPlaying( TRUE ); |
81 | } | 81 | } |
82 | 82 | ||
83 | void MediaPlayer::setPlaying( bool play ) { | 83 | void MediaPlayer::setPlaying( bool play ) { |
84 | if ( !play ) { | 84 | if ( !play ) { |
85 | return; | 85 | return; |
86 | } | 86 | } |
87 | 87 | ||
88 | if ( mediaPlayerState->paused() ) { | 88 | if ( mediaPlayerState->paused() ) { |
89 | mediaPlayerState->setPaused( FALSE ); | 89 | mediaPlayerState->setPaused( FALSE ); |
90 | return; | 90 | return; |
91 | } | 91 | } |
92 | 92 | ||
93 | QString tickerText, time, fileName; | 93 | QString tickerText, time, fileName; |
94 | if( playList->whichList() == 0 ) { //check for filelist | 94 | if( playList->whichList() == 0 ) { //check for filelist |
95 | const DocLnk *playListCurrent = playList->current(); | 95 | const DocLnk *playListCurrent = playList->current(); |
96 | if ( playListCurrent != NULL ) { | 96 | if ( playListCurrent != NULL ) { |
97 | currentFile = playListCurrent; | 97 | currentFile = playListCurrent; |
98 | } | 98 | } |
99 | xineControl->play( currentFile->file() ); | 99 | xineControl->play( currentFile->file() ); |
100 | fileName = currentFile->name(); | 100 | fileName = currentFile->name(); |
101 | long seconds = mediaPlayerState->length();// | 101 | long seconds = mediaPlayerState->length();// |
102 | time.sprintf("%li:%02i", seconds/60, (int)seconds%60 ); | 102 | time.sprintf("%li:%02i", seconds/60, (int)seconds%60 ); |
103 | qDebug(time); | 103 | //qDebug(time); |
104 | 104 | ||
105 | } else { //if playing in file list.. play in a different way | 105 | } else { |
106 | // random and looping settings enabled causes problems here, | 106 | //if playing in file list.. play in a different way |
107 | // since there is no selected file in the playlist, but a selected file in the file list, | 107 | // random and looping settings enabled causes problems here, |
108 | // so we remember and shutoff | 108 | // since there is no selected file in the playlist, but a selected file in the file list, |
109 | // so we remember and shutoff | ||
109 | l = mediaPlayerState->looping(); | 110 | l = mediaPlayerState->looping(); |
110 | if(l) | 111 | if(l) { |
111 | mediaPlayerState->setLooping( false ); | 112 | mediaPlayerState->setLooping( false ); |
113 | } | ||
112 | r = mediaPlayerState->shuffled(); | 114 | r = mediaPlayerState->shuffled(); |
113 | mediaPlayerState->setShuffled(false); | 115 | mediaPlayerState->setShuffled( false ); |
114 | 116 | ||
115 | fileName = playList->currentFileListPathName(); | 117 | fileName = playList->currentFileListPathName(); |
116 | xineControl->play( fileName); | 118 | xineControl->play( fileName ); |
117 | long seconds = mediaPlayerState->length();// | 119 | long seconds = mediaPlayerState->length(); |
118 | time.sprintf("%li:%02i", seconds/60, (int)seconds%60 ); | 120 | time.sprintf("%li:%02i", seconds/60, (int)seconds%60 ); |
119 | qDebug(time); | 121 | //qDebug(time); |
120 | if( fileName.left(4) != "http" ) | 122 | if( fileName.left(4) != "http" ) { |
121 | fileName = QFileInfo( fileName).baseName(); | 123 | fileName = QFileInfo( fileName ).baseName(); |
124 | } | ||
122 | 125 | ||
123 | } | 126 | } |
124 | if( fileName.left(4) == "http" ) | 127 | |
125 | tickerText= tr( " File: " ) + fileName; | 128 | if( fileName.left(4) == "http" ) { |
126 | else | 129 | if ( xineControl->getMetaInfo().isEmpty() ) { |
127 | tickerText = tr( " File: " ) + fileName + tr(", Length: ") + time; | 130 | tickerText = tr( " File: " ) + fileName; |
131 | } else { | ||
132 | tickerText = xineControl->getMetaInfo(); | ||
133 | } | ||
134 | } else { | ||
135 | if ( xineControl->getMetaInfo().isEmpty() ) { | ||
136 | tickerText = tr( " File: " ) + fileName + tr( ", Length: " ) + time + " "; | ||
137 | } else { | ||
138 | tickerText = xineControl->getMetaInfo() + " Length: " + time + " "; | ||
139 | } | ||
140 | } | ||
128 | audioUI->setTickerText( tickerText ); | 141 | audioUI->setTickerText( tickerText ); |
129 | } | 142 | } |
130 | 143 | ||
131 | 144 | ||
132 | void MediaPlayer::prev() { | 145 | void MediaPlayer::prev() { |
133 | if(playList->whichList() == 0) { //if using the playlist | 146 | if( playList->whichList() == 0 ) { //if using the playlist |
134 | if ( playList->prev() ) { | 147 | if ( playList->prev() ) { |
135 | play(); | 148 | play(); |
136 | } else if ( mediaPlayerState->looping() ) { | 149 | } else if ( mediaPlayerState->looping() ) { |
137 | if ( playList->last() ) { | 150 | if ( playList->last() ) { |
138 | play(); | 151 | play(); |
139 | } | 152 | } |
140 | } else { | 153 | } else { |
141 | mediaPlayerState->setList(); | 154 | mediaPlayerState->setList(); |
142 | } | 155 | } |
143 | } | 156 | } |
144 | } | 157 | } |
145 | 158 | ||
146 | 159 | ||
147 | void MediaPlayer::next() { | 160 | void MediaPlayer::next() { |
148 | 161 | ||
149 | if(playList->whichList() == 0) { //if using the playlist | 162 | if(playList->whichList() == 0) { //if using the playlist |
150 | if ( playList->next() ) { | 163 | if ( playList->next() ) { |
151 | play(); | 164 | play(); |
152 | } else if ( mediaPlayerState->looping() ) { | 165 | } else if ( mediaPlayerState->looping() ) { |
153 | if ( playList->first() ) { | 166 | if ( playList->first() ) { |
154 | play(); | 167 | play(); |
155 | } | 168 | } |
156 | } else { | 169 | } else { |
157 | mediaPlayerState->setList(); | 170 | mediaPlayerState->setList(); |
@@ -171,127 +184,127 @@ void MediaPlayer::startDecreasingVolume() { | |||
171 | volumeDirection = -1; | 184 | volumeDirection = -1; |
172 | startTimer( 100 ); | 185 | startTimer( 100 ); |
173 | volControl->decVol(2); | 186 | volControl->decVol(2); |
174 | } | 187 | } |
175 | 188 | ||
176 | 189 | ||
177 | void MediaPlayer::startIncreasingVolume() { | 190 | void MediaPlayer::startIncreasingVolume() { |
178 | volumeDirection = +1; | 191 | volumeDirection = +1; |
179 | startTimer( 100 ); | 192 | startTimer( 100 ); |
180 | volControl->incVol(2); | 193 | volControl->incVol(2); |
181 | } | 194 | } |
182 | 195 | ||
183 | 196 | ||
184 | bool drawnOnScreenDisplay = FALSE; | 197 | bool drawnOnScreenDisplay = FALSE; |
185 | unsigned int onScreenDisplayVolume = 0; | 198 | unsigned int onScreenDisplayVolume = 0; |
186 | const int yoff = 110; | 199 | const int yoff = 110; |
187 | 200 | ||
188 | void MediaPlayer::stopChangingVolume() { | 201 | void MediaPlayer::stopChangingVolume() { |
189 | killTimers(); | 202 | killTimers(); |
190 | // Get rid of the on-screen display stuff | 203 | // Get rid of the on-screen display stuff |
191 | drawnOnScreenDisplay = FALSE; | 204 | drawnOnScreenDisplay = FALSE; |
192 | onScreenDisplayVolume = 0; | 205 | onScreenDisplayVolume = 0; |
193 | int w=0; | 206 | int w=0; |
194 | int h=0; | 207 | int h=0; |
195 | if( !xineControl->hasVideo()) { | 208 | if( !xineControl->hasVideo() ) { |
196 | w = audioUI->width(); | 209 | w = audioUI->width(); |
197 | h = audioUI->height(); | 210 | h = audioUI->height(); |
198 | audioUI->repaint( (w - 200) / 2, h - yoff, 200 + 9, 70, FALSE ); | 211 | audioUI->repaint( ( w - 200 ) / 2, h - yoff, 200 + 9, 70, FALSE ); |
199 | } else { | 212 | } else { |
200 | w = videoUI->width(); | 213 | w = videoUI->width(); |
201 | h = videoUI->height(); | 214 | h = videoUI->height(); |
202 | videoUI->repaint( (w - 200) / 2, h - yoff, 200 + 9, 70, FALSE ); | 215 | videoUI->repaint( ( w - 200 ) / 2, h - yoff, 200 + 9, 70, FALSE ); |
203 | } | 216 | } |
204 | } | 217 | } |
205 | 218 | ||
206 | 219 | ||
207 | void MediaPlayer::timerEvent( QTimerEvent * ) { | 220 | void MediaPlayer::timerEvent( QTimerEvent * ) { |
208 | if ( volumeDirection == +1 ) { | 221 | if ( volumeDirection == +1 ) { |
209 | volControl->incVol(2); | 222 | volControl->incVol( 2 ); |
210 | } else if ( volumeDirection == -1 ) { | 223 | } else if ( volumeDirection == -1 ) { |
211 | volControl->decVol(2); | 224 | volControl->decVol( 2 ); |
212 | } | 225 | } |
213 | 226 | ||
214 | 227 | ||
215 | // TODO FIXME | 228 | // TODO FIXME |
216 | // huh?? | 229 | // huh?? |
217 | unsigned int v= 0; | 230 | unsigned int v= 0; |
218 | v = volControl->volume(); | 231 | v = volControl->volume(); |
219 | v = v / 10; | 232 | v = v / 10; |
220 | 233 | ||
221 | if ( drawnOnScreenDisplay && onScreenDisplayVolume == v ) { | 234 | if ( drawnOnScreenDisplay && onScreenDisplayVolume == v ) { |
222 | return; | 235 | return; |
223 | } | 236 | } |
224 | 237 | ||
225 | int w=0; int h=0; | 238 | int w=0; int h=0; |
226 | if( !xineControl->hasVideo()) { | 239 | if( !xineControl->hasVideo() ) { |
227 | w = audioUI->width(); | 240 | w = audioUI->width(); |
228 | h = audioUI->height(); | 241 | h = audioUI->height(); |
229 | 242 | ||
230 | if ( drawnOnScreenDisplay ) { | 243 | if ( drawnOnScreenDisplay ) { |
231 | if ( onScreenDisplayVolume > v ) { | 244 | if ( onScreenDisplayVolume > v ) { |
232 | audioUI->repaint( (w - 200) / 2 + v * 20 + 0, h - yoff + 40, (onScreenDisplayVolume - v) * 20 + 9, 30, FALSE ); | 245 | audioUI->repaint( ( w - 200 ) / 2 + v * 20 + 0, h - yoff + 40, ( onScreenDisplayVolume - v ) * 20 + 9, 30, FALSE ); |
233 | } | 246 | } |
234 | } | 247 | } |
235 | drawnOnScreenDisplay = TRUE; | 248 | drawnOnScreenDisplay = TRUE; |
236 | onScreenDisplayVolume = v; | 249 | onScreenDisplayVolume = v; |
237 | QPainter p( audioUI ); | 250 | QPainter p( audioUI ); |
238 | p.setPen( QColor( 0x10, 0xD0, 0x10 ) ); | 251 | p.setPen( QColor( 0x10, 0xD0, 0x10 ) ); |
239 | p.setBrush( QColor( 0x10, 0xD0, 0x10 ) ); | 252 | p.setBrush( QColor( 0x10, 0xD0, 0x10 ) ); |
240 | 253 | ||
241 | QFont f; | 254 | QFont f; |
242 | f.setPixelSize( 20 ); | 255 | f.setPixelSize( 20 ); |
243 | f.setBold( TRUE ); | 256 | f.setBold( TRUE ); |
244 | p.setFont( f ); | 257 | p.setFont( f ); |
245 | p.drawText( (w - 200) / 2, h - yoff + 20, tr("Volume") ); | 258 | p.drawText( (w - 200) / 2, h - yoff + 20, tr("Volume") ); |
246 | 259 | ||
247 | for ( unsigned int i = 0; i < 10; i++ ) { | 260 | for ( unsigned int i = 0; i < 10; i++ ) { |
248 | if ( v > i ) { | 261 | if ( v > i ) { |
249 | p.drawRect( (w - 200) / 2 + i * 20 + 0, h - yoff + 40, 9, 30 ); | 262 | p.drawRect( ( w - 200 ) / 2 + i * 20 + 0, h - yoff + 40, 9, 30 ); |
250 | } else { | 263 | } else { |
251 | p.drawRect( (w - 200) / 2 + i * 20 + 3, h - yoff + 50, 3, 10 ); | 264 | p.drawRect( ( w - 200 ) / 2 + i * 20 + 3, h - yoff + 50, 3, 10 ); |
252 | } | 265 | } |
253 | } | 266 | } |
254 | } else { | 267 | } else { |
255 | w = videoUI->width(); | 268 | w = videoUI->width(); |
256 | h = videoUI->height(); | 269 | h = videoUI->height(); |
257 | 270 | ||
258 | if ( drawnOnScreenDisplay ) { | 271 | if ( drawnOnScreenDisplay ) { |
259 | if ( onScreenDisplayVolume > v ) { | 272 | if ( onScreenDisplayVolume > v ) { |
260 | videoUI->repaint( (w - 200) / 2 + v * 20 + 0, h - yoff + 40, (onScreenDisplayVolume - v) * 20 + 9, 30, FALSE ); | 273 | videoUI->repaint( (w - 200) / 2 + v * 20 + 0, h - yoff + 40, ( onScreenDisplayVolume - v ) * 20 + 9, 30, FALSE ); |
261 | } | 274 | } |
262 | } | 275 | } |
263 | drawnOnScreenDisplay = TRUE; | 276 | drawnOnScreenDisplay = TRUE; |
264 | onScreenDisplayVolume = v; | 277 | onScreenDisplayVolume = v; |
265 | QPainter p( videoUI ); | 278 | QPainter p( videoUI ); |
266 | p.setPen( QColor( 0x10, 0xD0, 0x10 ) ); | 279 | p.setPen( QColor( 0x10, 0xD0, 0x10 ) ); |
267 | p.setBrush( QColor( 0x10, 0xD0, 0x10 ) ); | 280 | p.setBrush( QColor( 0x10, 0xD0, 0x10 ) ); |
268 | 281 | ||
269 | QFont f; | 282 | QFont f; |
270 | f.setPixelSize( 20 ); | 283 | f.setPixelSize( 20 ); |
271 | f.setBold( TRUE ); | 284 | f.setBold( TRUE ); |
272 | p.setFont( f ); | 285 | p.setFont( f ); |
273 | p.drawText( (w - 200) / 2, h - yoff + 20, tr("Volume") ); | 286 | p.drawText( (w - 200) / 2, h - yoff + 20, tr( "Volume" ) ); |
274 | 287 | ||
275 | for ( unsigned int i = 0; i < 10; i++ ) { | 288 | for ( unsigned int i = 0; i < 10; i++ ) { |
276 | if ( v > i ) { | 289 | if ( v > i ) { |
277 | p.drawRect( (w - 200) / 2 + i * 20 + 0, h - yoff + 40, 9, 30 ); | 290 | p.drawRect( (w - 200) / 2 + i * 20 + 0, h - yoff + 40, 9, 30 ); |
278 | } else { | 291 | } else { |
279 | p.drawRect( (w - 200) / 2 + i * 20 + 3, h - yoff + 50, 3, 10 ); | 292 | p.drawRect( (w - 200) / 2 + i * 20 + 3, h - yoff + 50, 3, 10 ); |
280 | } | 293 | } |
281 | } | 294 | } |
282 | } | 295 | } |
283 | } | 296 | } |
284 | 297 | ||
285 | 298 | ||
286 | void MediaPlayer::blank( bool b ) { | 299 | void MediaPlayer::blank( bool b ) { |
287 | fd=open("/dev/fb0",O_RDWR); | 300 | fd=open("/dev/fb0",O_RDWR); |
288 | if (fd != -1) { | 301 | if (fd != -1) { |
289 | if ( b ) { | 302 | if ( b ) { |
290 | qDebug("do blanking"); | 303 | qDebug("do blanking"); |
291 | ioctl( fd, FBIOBLANK, 3 ); | 304 | ioctl( fd, FBIOBLANK, 3 ); |
292 | isBlanked = TRUE; | 305 | isBlanked = TRUE; |
293 | } else { | 306 | } else { |
294 | qDebug("do unblanking"); | 307 | qDebug("do unblanking"); |
295 | ioctl( fd, FBIOBLANK, 0); | 308 | ioctl( fd, FBIOBLANK, 0); |
296 | isBlanked = FALSE; | 309 | isBlanked = FALSE; |
297 | } | 310 | } |
@@ -306,28 +319,28 @@ void MediaPlayer::keyReleaseEvent( QKeyEvent *e) { | |||
306 | ////////////////////////////// Zaurus keys | 319 | ////////////////////////////// Zaurus keys |
307 | case Key_Home: | 320 | case Key_Home: |
308 | break; | 321 | break; |
309 | case Key_F9: //activity | 322 | case Key_F9: //activity |
310 | break; | 323 | break; |
311 | case Key_F10: //contacts | 324 | case Key_F10: //contacts |
312 | break; | 325 | break; |
313 | case Key_F11: //menu | 326 | case Key_F11: //menu |
314 | break; | 327 | break; |
315 | case Key_F12: //home | 328 | case Key_F12: //home |
316 | qDebug("Blank here"); | 329 | qDebug("Blank here"); |
317 | // mediaPlayerState->toggleBlank(); | 330 | // mediaPlayerState->toggleBlank(); |
318 | break; | 331 | break; |
319 | case Key_F13: //mail | 332 | case Key_F13: //mail |
320 | qDebug("Blank here"); | 333 | qDebug("Blank here"); |
321 | // mediaPlayerState->toggleBlank(); | 334 | // mediaPlayerState->toggleBlank(); |
322 | break; | 335 | break; |
323 | } | 336 | } |
324 | } | 337 | } |
325 | 338 | ||
326 | void MediaPlayer::cleanUp() {// this happens on closing | 339 | void MediaPlayer::cleanUp() {// this happens on closing |
327 | Config cfg( "OpiePlayer" ); | 340 | Config cfg( "OpiePlayer" ); |
328 | mediaPlayerState->writeConfig( cfg ); | 341 | mediaPlayerState->writeConfig( cfg ); |
329 | playList->writeConfig( cfg ); | 342 | playList->writeConfig( cfg ); |
330 | 343 | ||
331 | // QPEApplication::grabKeyboard(); | 344 | // QPEApplication::grabKeyboard(); |
332 | // QPEApplication::ungrabKeyboard(); | 345 | // QPEApplication::ungrabKeyboard(); |
333 | } | 346 | } |