author | llornkcor <llornkcor> | 2002-08-03 11:26:12 (UTC) |
---|---|---|
committer | llornkcor <llornkcor> | 2002-08-03 11:26:12 (UTC) |
commit | 3b1ab71b7bfe42310661764e1089200290c7b817 (patch) (unidiff) | |
tree | 361ad970ec2f4c06bd7d9cc1a94b45040539f844 /noncore/multimedia/opieplayer2/mediaplayer.cpp | |
parent | 7d4b246bc728b73e9d38e110619222dd89c1fd1c (diff) | |
download | opie-3b1ab71b7bfe42310661764e1089200290c7b817.zip opie-3b1ab71b7bfe42310661764e1089200290c7b817.tar.gz opie-3b1ab71b7bfe42310661764e1089200290c7b817.tar.bz2 |
initial fx for time readout
Diffstat (limited to 'noncore/multimedia/opieplayer2/mediaplayer.cpp') (more/less context) (ignore whitespace changes)
-rw-r--r-- | noncore/multimedia/opieplayer2/mediaplayer.cpp | 22 |
1 files changed, 20 insertions, 2 deletions
diff --git a/noncore/multimedia/opieplayer2/mediaplayer.cpp b/noncore/multimedia/opieplayer2/mediaplayer.cpp index 13cc4ed..5411a64 100644 --- a/noncore/multimedia/opieplayer2/mediaplayer.cpp +++ b/noncore/multimedia/opieplayer2/mediaplayer.cpp | |||
@@ -71,10 +71,28 @@ void MediaPlayer::setPlaying( bool play ) { | |||
71 | if ( playListCurrent != NULL ) { | 71 | if ( playListCurrent != NULL ) { |
72 | currentFile = playListCurrent; | 72 | currentFile = playListCurrent; |
73 | } | 73 | } |
74 | |||
75 | xineControl->play( currentFile->file() ); | ||
74 | 76 | ||
75 | audioUI->setTickerText( currentFile->file( ) ); | 77 | xineControl->length(); |
78 | long seconds = mediaPlayerState->length();// | ||
79 | QString time; time.sprintf("%li:%02i", seconds/60, (int)seconds%60 ); | ||
80 | qDebug(time); | ||
76 | 81 | ||
77 | xineControl->play( currentFile->file() ); | 82 | QString tickerText; |
83 | if( currentFile->file().left(4) == "http" ) | ||
84 | tickerText= tr( " File: " ) + currentFile->name(); | ||
85 | else | ||
86 | tickerText = tr( " File: " ) + currentFile->name() + tr(", Length: ") + time; | ||
87 | |||
88 | // QString fileInfo = mediaPlayerState->curDecoder()->fileInfo(); | ||
89 | |||
90 | // if ( !fileInfo.isEmpty() ) | ||
91 | // tickerText += ", " + fileInfo; | ||
92 | // audioUI->setTickerText( tickerText + "." ); | ||
93 | |||
94 | audioUI->setTickerText( currentFile->file( ) ); | ||
95 | |||
78 | } | 96 | } |
79 | 97 | ||
80 | 98 | ||