void newGameImg_Tapped(object sender, TappedRoutedEventArgs e) { NavigationParams parameters = new NavigationParams(); parameters.mode = gameMode; this.Frame.Navigate(typeof(GamePage), parameters); }
private void MultiplayerBtn_Click(object sender, RoutedEventArgs e) { NavigationParams parameters = new NavigationParams(); parameters.mode = GameMode.TwoPlayer; this.Frame.Navigate(typeof(GamePage), parameters); }
/// <summary> /// Invoked when this page is about to be displayed in a Frame. /// </summary> /// <param name="e">Event data that describes how this page was reached. /// This parameter is typically used to configure the page.</param> protected override void OnNavigatedTo(NavigationEventArgs e) { NavigationParams parameters = e.Parameter as NavigationParams; if (parameters != null) { gameMode = parameters.mode; } }