private void Prev_Step_Click(object sender, RoutedEventArgs e) { if (currentStep > 0) { recipeProfilePage._currentStep = currentStep - 1; StepByStepPage prevStep = recipeProfilePage.mainStep.allSteps.ElementAt(currentStep - 1); this.NavigationService.Navigate(prevStep); } }
public StepMainPage(Recipe recipe) { InitializeComponent(); for (int i = 0; i < recipe._steps.Count; i++) { StepByStepPage step = new StepByStepPage(recipe, i); allSteps.Add(step); } }
private void Back_Click(object sender, RoutedEventArgs e) { RecipeProfilePage recipeProfile = GetRecipeProfilePage(); recipeProfile._completionPage = null; recipeProfile._currentStep = currentRecipe._steps.Count - 1; recipeProfile._startButton.initAppearance(TransitionPageButton.Orientation.FORWARD, "CONTINUE"); StepByStepPage step = recipeProfile.mainStep.allSteps.ElementAt(currentRecipe._steps.Count - 1); this.NavigationService.Navigate(step); }
private void StartButton_Click(object sender, RoutedEventArgs e) { if (_completionPage == null && _currentStep == 0) { this.NavigationService.Navigate(GetStepMainPage().allSteps.ElementAt(0)); } else if (_completionPage == null && _currentStep > 0) { StepByStepPage step = GetStepMainPage().allSteps.ElementAt(_currentStep); this.NavigationService.Navigate(step); } else if (_completionPage != null) { this.NavigationService.Navigate(_completionPage); } }