// Event handler for when the Quit Game menu entry is selected. void QuitGameSelected(object sender, PlayerIndexEventArgs e) { MessageBoxScreen confirmQuitMessageBox = new MessageBoxScreen(promptMessage, acceptMessage); confirmQuitMessageBox.Accepted += ConfirmQuitAccepted; ScreenManager.AddScreen(confirmQuitMessageBox); }
protected override void OnCancel() { MessageBoxScreen confirmExitMessageBox = new MessageBoxScreen(exitPrompt, acceptPrompt); confirmExitMessageBox.Accepted += ConfirmExitSelected; ScreenManager.AddScreen(confirmExitMessageBox); }