/// <summary> /// Event handler for when the Quit Game menu entry is selected. /// </summary> void CheckQuitGame(PlayerIndexEventArgs e) { CheckQuitScreen confirmQuitMessageBox = new CheckQuitScreen(); confirmQuitMessageBox.Accepted += ConfirmQuitMessageBoxAccepted; ScreenManager.AddScreen(confirmQuitMessageBox, ControllingPlayer); }
/// <summary> /// When the user cancels the main menu, ask if they want to exit the sample. /// </summary> protected void OnExit(PlayerIndexEventArgs e) { CheckQuitScreen confirmExitMessageBox = new CheckQuitScreen(); confirmExitMessageBox.Accepted += ConfirmExitMessageBoxAccepted; ScreenManager.AddScreen(confirmExitMessageBox, e.PlayerIndex); }
/// <summary> /// Event handler for when the Quit Game menu entry is selected. void CheckMainMenu(PlayerIndexEventArgs e) { CheckQuitScreen confirmMainMenu = new CheckQuitScreen(); confirmMainMenu.Accepted += ConfirmMainMenuMessageBoxAccepted; ScreenManager.AddScreen(confirmMainMenu, ControllingPlayer); }