Exemplo n.º 1
0
 public void PopulateFriends(IList <PlayerFriendsClientModel> friends)
 {
     Friends.AddRange(from f in friends
                      select new FriendModel
     {
         PaladinsPlayerId = Convert.ToInt32(f.PlayerId),
         AccountId        = Convert.ToInt32(f.AccountId),
         Name             = f.Name
     });
 }
Exemplo n.º 2
0
        async Task LoadToCollection(IEnumerable <Friend> friends)
        {
            await FriendsSemaphore.WaitAsync().ConfigureAwait(false);

            using (Friends.UpdatesBlock()) {
                Friends.Clear();
                Friends.AddRange(friends);
            }

            FriendsSemaphore.Release();
        }
Exemplo n.º 3
0
        protected override async Task OnInitializedAsync()
        {
            Game = await GameDataService.GetGameDetails(new Guid(GameId));

            Friends.AddRange((await FriendDataService.GetAllFriends()).ToList());
        }
Exemplo n.º 4
0
 public void AddFriends(IList <Player> newfriends)
 {
     Friends.AddRange(newfriends);
 }
Exemplo n.º 5
0
 public FriendList(IEnumerable <string> friends, IEnumerable <string> outRequests, IEnumerable <string> inRequests)
 {
     Friends.AddRange(friends);
     OpenFriendRequests.AddRange(outRequests);
     UnansweredFriendRequests.AddRange(inRequests);
 }