public void FillUserProfile(User userData) { if (!gameObject.activeSelf) { return; } _usernameText.text = userData.username; AsyncImageLoader.RequestImage(userData.pictureUrl, _profileImage); AsyncImageLoader.RequestImage(userData.clubPictureUrl, _clubImage); }
public void FillUserProfile(User userData, bool allowEdit) { if (!gameObject.activeSelf) { return; } _usernameInputField.text = userData.username; AsyncImageLoader.RequestImage(userData.pictureUrl, _profileImage); AsyncImageLoader.RequestImage(userData.clubPictureUrl, _clubImage); _changeUsernameButton.gameObject.SetActive(allowEdit); }
public void Initialize(int index, object data) { _index = index; var cardData = (CardItemData)data; _cardId = cardData.UserId; _nameText.text = cardData.Name; AsyncImageLoader.RequestImage(cardData.AvatarUrl, _avatarImage); AsyncImageLoader.RequestImage(cardData.ClubLogoUrl, _clubImage); OnSelected = new Action <string>(cardData.OnSelected); OnLongPressed = new Action <int, string>(cardData.OnLongPressed); }