public void BaseStyling() { Styler.SetTextColor(ErrorLabel, UIColor.Red); Styler.SetBorderRadius(AddImageButton, 20f); Styler.SetShadows(AddImageButton, UIColor.Black, 2, 3, 2f); Styler.SetTextColor(AddImageButton, UIColor.Clear); Styler.SetShadows(RegisterButton, UIColor.Black, 2, 3, 3f); }
public void UpdateCell(string postId, string userId, string authorId, string authorImagePath, string authorTag, string imagePath, string description, int likes, bool usesURL) { ImageService.Instance.LoadUrl(authorImagePath).DownSample(45, 45).Into(UserImageView); if (usesURL) { ImageService.Instance.LoadUrl(imagePath).DownSample(388, 388).Into(PostImageView); } else { ImageService.Instance.LoadFile(imagePath).DownSample(388, 388).Into(PostImageView); Debug.WriteLine(imagePath); } UserTagLabel.Text = authorTag; DescriptionLabel.Text = description; LikesCountLabel.Text = likes.ToString(); DataContext.UserId = userId; DataContext.PostId = postId; DataContext.AuthorId = authorId; if (userId == authorId) { DeleteButton.Hidden = false; } else { DeleteButton.Hidden = true; } Styler.SetTextColor(LikesCountLabel, Colors.mainFontColor); Styler.SetBorderRadius(UserImageView, UserImageView.Frame.Size.Width / 2); Styler.SetTextColor(DeleteButton, Colors.mainFontColor); Styler.SetTextColor(DeleteButton, UIColor.Red, UIControlState.Selected); }
public void UpdateCell(string userId, string targetUserId, string targetUserImagePath, string targetUserUsername, string targetUserUserTag) { ImageService.Instance.LoadUrl(targetUserImagePath).DownSample(62, 62).Into(UserImageView); UsernameLabel.Text = targetUserUsername; UserTagLabel.Text = targetUserUserTag; DataContext.UserId = userId; DataContext.TargetUserId = targetUserId; if (DataContext.UserIsFollowed) { FollowButton.SetTitle("Unfollow", UIControlState.Normal); } else { FollowButton.SetTitle("Follow", UIControlState.Normal); } Styler.SetBorderRadius(UserImageView, UserImageView.Frame.Size.Width / 2); Styler.SetBorderRadius(FollowButton, FollowButton.Frame.Size.Width / 12); Styler.SetBorders(FollowButton, Colors.mainFontColor, 0.5f); Styler.SetTextColor(FollowButton, Colors.secondFontColor); }
public void BaseStyling() { Styler.SetBorderRadius(UserImageView, UserImageView.Frame.Width / 2); Styler.SetBorders(EditUserButton, Colors.secondFontColor, 1f); Styler.SetBorderRadius(EditUserButton, EditUserButton.Frame.Width / 15); }