コード例 #1
0
ファイル: ListActionHelper.cs プロジェクト: paul-pagnan/helps
 public ActionClickListener(BookingsListAdapter listAdapter, ListView listView, List <WorkshopPreview> list, ListActionHelper actionHelper, bool sorting, bool isWorkshop, Android.Views.View dialogView = null) : base()
 {
     this.listAdapter  = listAdapter;
     this.listView     = listView;
     this.list         = list;
     this.actionHelper = actionHelper;
     this.sorting      = sorting;
     this.isWorkshop   = isWorkshop;
     this.dialogView   = dialogView;
 }
コード例 #2
0
 public bool Back()
 {
     if (viewFlipper.DisplayedChild > 0)
     {
         workshopListAdapter.Clear();
         NotifyListUpdate();
         CurrentWorkshopSet = 0;
         listActioner = null;
         ViewHelper.ToggleMenu(menu, false);
         return FlipView();
     }
     return false;
 }
コード例 #3
0
        private async void LoadWorkshops(int workshopSet, int position, bool localOnly, bool force = false)
        {
            if (CurrentWorkshopSet > 0)
            {
                cts.Cancel();
                workshopList = await Services.Workshop.GetWorkshops(cts.Token, workshopSet, localOnly, force);
                workshopListAdapter.Clear();
                workshopListAdapter.AddAll(workshopList, position);

                listActioner = new ListActionHelper(workshopListAdapter, workshopListView, this, true);
                ViewHelper.ToggleMenu(menu, true);
                RunOnUiThread(delegate
                {
                    if (workshopListAdapter.Count > 0)
                    {
                        FindViewById<ProgressBar>(Resource.Id.workshopLoading).Visibility = ViewStates.Gone;
                        NotifyWorkshopListUpdate();
                    } else if (!localOnly)
                    {
                        FindViewById<ProgressBar>(Resource.Id.workshopLoading).Visibility = ViewStates.Gone;
                        FindViewById<TextView>(Resource.Id.noWorkshops).Visibility = ViewStates.Visible;
                    }
                });               
            }
        }
コード例 #4
0
ファイル: ListActionHelper.cs プロジェクト: paul-pagnan/helps
 public MultiClickListener(ListActionHelper actionHelper)
 {
     this.actionHelper = actionHelper;
 }
コード例 #5
0
ファイル: ListActionHelper.cs プロジェクト: paul-pagnan/helps
 public ActionClickListener(BookingsListAdapter listAdapter, ListView listView, List<WorkshopPreview> list, ListActionHelper actionHelper, bool sorting, bool isWorkshop, Android.Views.View dialogView = null)
     : base()
 {
     this.listAdapter = listAdapter;
     this.listView = listView;
     this.list = list;
     this.actionHelper = actionHelper;
     this.sorting = sorting;
     this.isWorkshop = isWorkshop;
     this.dialogView = dialogView;
 }
コード例 #6
0
ファイル: ListActionHelper.cs プロジェクト: paul-pagnan/helps
 public MultiClickListener(ListActionHelper actionHelper)
 {
     this.actionHelper = actionHelper;
 }
コード例 #7
0
 private async void InitList(Android.Views.View context, Android.Views.LayoutInflater inflater)
 {
     cts.Cancel();
     //Load from local first
     await Task.Factory.StartNew(() => LoadData(context, true));
     listActioner = new ListActionHelper(listAdapter, listView, activity, isWorkshop);
     //Do background refresh
     await Task.Factory.StartNew(() => LoadData(context, false));
 }