protected override void OnAppearing()
 {
     base.OnAppearing();
     if (Sessions.Count == 0)
     {
         var sessions = SessionsDataSource.GetSessions();
         foreach (var session in sessions)
         {
             Sessions.Add(session);
         }
     }
 }
示例#2
0
 public async Task LoadDataAsync()
 {
     await Task.Run(() => {
         if (Sessions.Count == 0)
         {
             var sessions = SessionsDataSource.GetSessions();
             foreach (var session in sessions)
             {
                 Sessions.Add(session);
             }
         }
     });
 }