private void BindDataWithStatus(PassStatus status) { RunOnUiThread( () => { DisplayPass.ClearThenAddRange(SourcePass.Where(p => p.Status == status).ToList()); var adapter = new PassListAdapter(this, DisplayPass); _listView.Adapter = adapter; adapter.ElectronicPassSelected += delegate(object sender, PassListAdapter.ElectronicPassSelectedEventArgs e) { MoveToNextView(e.SelectedPass); }; } ); }
private void ReloadTableSource(PassStatus status) { DisplayPass.ClearThenAddRange(SourcePass.Where(p => p.Status == status).ToList()); var source = new PassTableSource(DisplayPass); passTable.Source = source; source.PassSelected += delegate(object sender, PassTableSource.PassSelectedEventArgs e) { SelectedPass = e.SelectedPass; InvokeOnMainThread(() => { PerformSegue("moveToPassDetailViewSegue", this); }); }; InvokeOnMainThread( () => { passTable.ReloadData(); } ); }