예제 #1
0
        public async Task RefreshtrajetList()
        {
            try
            {
                m_refresher.Refreshing = true;

                List <Trajet> lstrajetsToShow = await Trajet.GetAlltrajetsToShowOnScreen(new FileAccessManager());

                m_adapter.UpdateListetrajets(lstrajetsToShow);

                if (lstrajetsToShow.Count == 0)
                {
                    m_textviewEmptyList.Visibility = ViewStates.Visible;
                }
                else
                {
                    m_textviewEmptyList.Visibility = ViewStates.Gone;
                }

                m_refresher.Refreshing = false;
            }
            catch (Exception e)
            {
                MobileCenter_Helper.ReportError(new FileAccessManager(), e, GetType().Name, MethodBase.GetCurrentMethod().Name);
            }
        }