private void StopThread() { if (_thread != null) { _thread.Dispose(); _thread = null; } }
private void StartThread() { if (_thread != null) { StopThread(); } _thread = new LoopThread(OnEventTick); }