using System; using Gtk; using GLib; class X { static void Main (string [] args) { Application.Init (); GLib.Timeout.Add (3000, delegate { Console.WriteLine ("At {0}", DateTime.Now); System.Threading.Thread.Sleep (3000); Console.WriteLine ("Leave at {0}", DateTime.Now); return true; }); Console.WriteLine ("At {0}", DateTime.Now); Application.Run (); } }