Exemplo n.º 1
0
 static void Main()
 {
     Application.EnableVisualStyles();
     Application.SetCompatibleTextRenderingDefault(false);
     using (MainWindow mainWindow = new MainWindow())
     {
         Application.Run(mainWindow);
     }
 }
Exemplo n.º 2
0
        static void Main()
        {
            Application.EnableVisualStyles();
                        Application.SetCompatibleTextRenderingDefault(false);
                        System.DateTime lastTime;

                        MainWindow mainWindow = new MainWindow();
                        mainWindow.Show();
                        lastTime = DateTime.Now;

                        while (mainWindow.Created)
                        {

                                mainWindow.Update((DateTime.Now-lastTime).TotalSeconds);
                                lastTime = DateTime.Now;
                                mainWindow.Render();
                                Application.DoEvents();
                        }
        }