#include "TickWorker.h" #include "Block.h" TickWorker::TickWorker( TickQueue* queue ) : Thread(), queue( queue ), waiting( 0 ) { start(); } TickWorker::~TickWorker() { queue->release(); } void TickWorker::thread() { Block* zTickBlock = queue->zNextBlock( waiting ); while( zTickBlock ) { zTickBlock->tick( queue ); zTickBlock = queue->zNextBlock( waiting ); } } bool TickWorker::isWaiting() const { return waiting; }