diff options
Diffstat (limited to 'playerwidget.cpp')
-rw-r--r-- | playerwidget.cpp | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/playerwidget.cpp b/playerwidget.cpp index dc6d1aa..92bfda7 100644 --- a/playerwidget.cpp +++ b/playerwidget.cpp @@ -631,9 +631,6 @@ void PlayerWidget::play(const QString &fullPath){ mCurrentTE->append(QString("%1 %2").arg(tr("Genre:"), -20).arg(genre)); mCurrentTE->append(QString("%1 %2").arg(tr("Track:"), -20).arg(track, 3, 10, QChar('0'))); mCurrentTE->append(QString("%1 %2").arg(tr("Year:"), -20).arg(year, 4, 10)); - int minutes = mDurSecs / 60; - int seconds = mDurSecs % 60; - mCurrentTE->append(QString("%1 %2:%3").arg(tr("Length:"), -20).arg(minutes, 2, 10, QChar('0')).arg(seconds, 2, 10, QChar('0'))); mPlayA->trigger(); } @@ -696,6 +693,9 @@ void PlayerWidget::setDuration(qint64 dur){ mDurSecs = dur / 1000; mSongSlider->setMinimum(0); mSongSlider->setMaximum(mDurSecs); + int minutes = mDurSecs / 60; + int seconds = mDurSecs % 60; + mCurrentTE->append(QString("%1 %2:%3").arg(tr("Length:"), -20).arg(minutes, 2, 10, QChar('0')).arg(seconds, 2, 10, QChar('0'))); } void PlayerWidget::continuePlaying(QMediaPlayer::State state){ |