Prevent killing timer with wrong id

This commit is contained in:
Klaus Basan
2016-11-15 23:19:19 +01:00
parent 2e5176ebcc
commit 871a1dd321
2 changed files with 6 additions and 13 deletions

View File

@@ -69,9 +69,9 @@ namespace BlackGui
void CLoadIndicator::setAnimationDelay(int delay)
{
if (this->m_timerId != -1) { killTimer(this->m_timerId); }
this->m_delayMs = delay;
if (this->m_timerId != -1) { this->m_timerId = startTimer(this->m_delayMs); }
if (this->m_timerId != -1) { killTimer(this->m_timerId); }
this->m_timerId = startTimer(this->m_delayMs);
}
void CLoadIndicator::setColor(const QColor &color)