public void ExecuteItemTappedCommand(Recipe selectedRecipe) { NavigationParameters Parameters = new NavigationParameters(); Parameters.Add("recipe", selectedRecipe); TestableNavigation.TestableNavigateAsync(NavigationService, nameof(HW3N.Views.RecipeDetailPage), Parameters, false, true).ConfigureAwait(false); }
public override async void OnNavigatedTo(INavigationParameters parameters) { Obj2 = (string)parameters["text"]; if (await _pageDialogService.DisplayAlertAsync("This is my title", "You navigated here, do you want to go back?", "Yes, go back", "No, stay here").ConfigureAwait(true)) { //await _navigationService.GoBackAsync(("action", "go back"), ("previousPage", nameof(ThirdPage)), ("text", parameters["text"])).ConfigureAwait(true); await TestableNavigation.TestableGoBackAsyncWithParams(_navigationService, new NavigationParameters($"?action=go back&previousPage={nameof(ThirdPage)}&text={parameters["text"]}"), false, false).ConfigureAwait(true); } }
private async void submitrecipe_execute() { if (await _pageDialog.DisplayAlertAsync("Question?", "Are you sure you'd like to save this?", "Continue", "Cancel")) { await TestableNavigation.TestableNavigateAsync(_navigationService, "MainPage", new NavigationParameters("?action=confirm"), false, false); NavigationParameters parameters = new NavigationParameters(); db.AddItem(MakeRecipe()); parameters.Add("recipe", recipe); _navigationService.NavigateAsync(nameof(MainPage), parameters, false, false); _recipeService.SubmitRecipe(null); } }
private void OnListViewItemSelected(object sender, SelectedItemChangedEventArgs e) { NavigationParameters Parameters = new NavigationParameters("Stuff To Say"); TestableNavigation.TestableNavigateAsync(NavigationService, nameof(HW3N.Views.RecipeDetailPage), Parameters, false, true).ConfigureAwait(false); }