C# Event Loop