示例#1
0
        protected override async void OnAppearing()
        {
            base.OnAppearing();

            if (mv.IsBusy == false)
            {
                PeopleListView.BeginRefresh();
                await mv.PopulatePeople();

                PeopleListView.ItemsSource = mv.GroupedPeople;
                PeopleListView.EndRefresh();
            }
        }
示例#2
0
        private void SearchBar_TextChanged(object sender, TextChangedEventArgs e)
        {
            PeopleListView.BeginRefresh();

            if (string.IsNullOrWhiteSpace(e.NewTextValue))
            {
                mv.createGrouping(false);
                PeopleListView.ItemsSource = mv.GroupedPeople;
            }
            else
            {
                mv.createGrouping(true, e.NewTextValue);
                PeopleListView.ItemsSource = mv.GroupedPeople;
            }

            PeopleListView.EndRefresh();
        }