diff --git a/src/gui/previews/AudioPreview.cpp b/src/gui/previews/AudioPreview.cpp index 22fc214..6c54134 100644 --- a/src/gui/previews/AudioPreview.cpp +++ b/src/gui/previews/AudioPreview.cpp @@ -28,15 +28,17 @@ SeekBar::SeekBar(QWidget* parent) QObject::connect(this, &QProgressBar::valueChanged, this, [this](int value) { QString formatter; if (AudioPlayer::getLengthInSeconds() >= 60 * 60 * 24) { - formatter = "dd:hh:mm:ss"; + formatter = "dd:hh:mm:ss.zzz"; } else if (AudioPlayer::getLengthInSeconds() >= 60 * 60) { - formatter = "hh:mm:ss"; + formatter = "hh:mm:ss.zzz"; + } else if (AudioPlayer::getLengthInSeconds() >= 60) { + formatter = "mm:ss.zzz"; } else { - formatter = "mm:ss"; + formatter = "ss.zzz"; } auto text = QString("%1 / %2").arg( - QTime(0,0).addSecs(static_cast(AudioPlayer::getPositionInSeconds())).toString(formatter), - QTime(0,0).addSecs(static_cast(AudioPlayer::getLengthInSeconds())).toString(formatter)); + QTime(0,0).addMSecs(static_cast(AudioPlayer::getPositionInSeconds() * 1000)).toString(formatter), + QTime(0,0).addMSecs(static_cast(AudioPlayer::getLengthInSeconds() * 1000)).toString(formatter)); this->label->setText(text); }); layout->addWidget(this->label); diff --git a/src/shared/thirdparty/sourcepp b/src/shared/thirdparty/sourcepp index 7839a45..b77b365 160000 --- a/src/shared/thirdparty/sourcepp +++ b/src/shared/thirdparty/sourcepp @@ -1 +1 @@ -Subproject commit 7839a45bf8fb221af698164e12bee57c901f9e0e +Subproject commit b77b3659fa503110135e858c5dbd644f39b6a50a