Use event handle instead of ugly Thread.Sleep