CComponentsTimer: rework timer class

This commit is contained in:
2016-04-25 10:26:32 +02:00
parent 10f17ad5ee
commit 4904279fd5
5 changed files with 144 additions and 61 deletions

View File

@@ -316,15 +316,15 @@ bool CComponentsFrmClock::startClock()
}
if (cl_timer == NULL){
cl_timer = new CComponentsTimer();
cl_timer = new CComponentsTimer(0);
if (cl_timer->OnTimer.empty()){
dprintf(DEBUG_INFO,"\033[33m[CComponentsFrmClock]\t[%s] init slot...\033[0m\n", __func__);
cl_timer->OnTimer.connect(cl_sl);
}
}
cl_timer->setTimerIntervall(cl_interval);
cl_timer->setTimerInterval(cl_interval);
if (cl_timer->isRun())
if (cl_timer->startTimer())
return true;
return false;