Implement several pieces of UI polish for badges.

This commit is contained in:
Alex Hart
2021-10-28 13:59:05 -03:00
committed by Greyson Parrelli
parent 186bd9db48
commit 755ec672c0
33 changed files with 364 additions and 113 deletions

View File

@@ -57,7 +57,11 @@ public class ConversationBannerView extends ConstraintLayout {
}
public void setBadge(@Nullable Recipient recipient) {
contactBadge.setBadgeFromRecipient(recipient);
if (recipient == null || recipient.isSelf()) {
contactBadge.setBadge(null);
} else {
contactBadge.setBadgeFromRecipient(recipient);
}
}
public void setAvatar(@NonNull GlideRequests requests, @Nullable Recipient recipient) {

View File

@@ -106,7 +106,11 @@ public class ConversationTitleView extends RelativeLayout {
this.avatar.setAvatar(glideRequests, recipient, false);
}
badge.setBadgeFromRecipient(recipient);
if (recipient == null || recipient.isSelf()) {
badge.setBadgeFromRecipient(null);
} else {
badge.setBadgeFromRecipient(recipient);
}
updateVerifiedSubtitleVisibility();
}