1
0
mirror of https://github.com/tomahawk-player/tomahawk.git synced 2025-08-25 23:06:23 +02:00

* Fixed crash in AudioControls. (merge)

This commit is contained in:
Christian Muehlhaeuser
2012-04-04 16:41:00 +02:00
parent eff42af593
commit aec7a0b140

View File

@@ -362,8 +362,12 @@ void
AudioControls::onPlaybackTimer( qint64 msElapsed )
{
const int seconds = msElapsed / 1000;
if ( seconds != m_lastTextSecondShown && !m_currentTrack.isNull() )
{
ui->timeLabel->setText( TomahawkUtils::timeToString( seconds ) );
ui->timeLeftLabel->setText( "-" + TomahawkUtils::timeToString( m_currentTrack->duration() - seconds ) );
m_lastTextSecondShown = seconds;
}
//tDebug( LOGEXTRA ) << Q_FUNC_INFO << "msElapsed =" << msElapsed << "and timer current time =" << m_sliderTimeLine.currentTime() << "and m_seekMsecs =" << m_seekMsecs;
if ( msElapsed > 0 && msElapsed != m_lastSliderCheck && m_seekMsecs == -1 && msElapsed - 500 < m_lastSliderCheck )