private static void Main(string[] args) { FormPositioner.PlaceConsoleOnSecondScreenIfPossible(); theGameCore = new GameCore.GameCore(); theGameCore.TheGameEventHandler += theGameCore_TheGameEventHandler; theGameCore.Start(); waitForClose.WaitOne(); // Console.ReadLine(); theGameCore.TheGameEventHandler -= theGameCore_TheGameEventHandler; }
private void ShowMenuForm() { theMenuForm = new MenuForm(this); Async.Do(delegate { Application.Run(theMenuForm); }); theMenuForm.Shown += delegate { Thread.Sleep(100); FormPositioner.PlaceNextToForm(theMenuForm, theKeyboardBindingsForm, FormPositioner.Locations.Left); }; }
private void ShowKeyboardBindingForm() { theKeyboardBindingsForm = new KeyboardBindingsForm(theRenderer.TheKeyBindings); Async.Do(delegate { Application.Run(theKeyboardBindingsForm); }); theKeyboardBindingsForm.Shown += delegate { FormPositioner.PlaceOnSecondScreenIfPossible(theKeyboardBindingsForm, FormPositioner.Locations.TopRight); }; // Wait for the form to start up. // Thread.Sleep(200); // FormPositioner.PlaceOnSecondScreenIfPossible(theKeyboardBindingsForm, FormPositioner.Locations.TopRight); }