Пример #1
0
        private void FriendsRepositoryLoaded(object sender, RepositoryLoadedEventArgs e)
        {
            var allFriends = _friendsRepository.Data.ToList();
            var onlineFriends = allFriends.Where(x => x.Online).ToList();

            AllFriendsModel.Set(allFriends);
            OnlineFriendsModel.Set(onlineFriends);
            
            UpdateOnlineCount();
            UpdateAllCount();
        }
Пример #2
0
 private void UserInfoLoaded(object sender, RepositoryLoadedEventArgs e)
 {
     FullUserName = _userInfoRepository.NotEmpty()
         ? $"{_userInfoRepository.Data.FirstName} {_userInfoRepository.Data.LastName}"
         : null;
 }
Пример #3
0
 private void UserAvatarLoaded(object sender, RepositoryLoadedEventArgs e)
 {
     if (_userAvatarRepository.NotEmpty())
     {
         Avatar = CreateBitmapImage(_userAvatarRepository.Data.Content);
     }
 }
Пример #4
0
 private void SessionInfoRepositoryLoaded(object sender, RepositoryLoadedEventArgs e)
 {
     Authenticated = _sessionInfoRepository.NotEmpty();
 }