private void GetDistanceOptions(Boolean init) { DistanceOptions.Add(5); DistanceOptions.Add(10); DistanceOptions.Add(50); DistanceOptions.Add(100); if (init) { Distance = DistanceOptions.First(); } }
public void OnNavigatedTo(NavigationParameters parameters) { GetCurrentUserLocation(); if (Distance == 0) { Distance = DistanceOptions.First(); } if (PageSize == 0) { PageSize = PageSizeOptions.First(); } }
public override async void OnNavigatedTo(object navigationParameter, Windows.UI.Xaml.Navigation.NavigationMode navigationMode, Dictionary <string, object> viewModelState) { Geolocator locator = new Geolocator(); Position = await locator.GetGeopositionAsync(); if (Distance == 0) { Distance = DistanceOptions.First(); } if (PageSize == 0) { PageSize = PageSizeOptions.First(); } }