Fixed / Improved timer handling in timer based component

This commit is contained in:
Klaus Basan
2014-09-25 03:13:45 +02:00
parent ef5f5bde0f
commit 84b5cee7d8
2 changed files with 2 additions and 1 deletions

View File

@@ -46,6 +46,7 @@ namespace BlackGui
void CTimerBasedComponent::fireTimer()
{
Q_ASSERT(this->m_timerSingleShot);
this->m_timer->start(); // restart other timer
this->m_timerSingleShot->start(10);
}
}

View File

@@ -46,7 +46,7 @@ namespace BlackGui
void setUpdateIntervalSeconds(int seconds) { this->setUpdateInterval(1000 * seconds); }
//! Stop timer
void stopTimer() { this->setUpdateInterval(-1); }
void stopTimer() { this->setUpdateInterval(-1); this->m_timerSingleShot->stop(); }
//! Fire the timer straight away
void fireTimer();