1
0
Fork 0
mirror of https://github.com/M66B/FairEmail.git synced 2024-12-30 19:56:10 +00:00

Optimization

This commit is contained in:
M66B 2024-08-03 12:14:34 +02:00
parent 426a16821f
commit 8944da79bf

View file

@ -1384,12 +1384,15 @@ public class AdapterMessage extends RecyclerView.Adapter<AdapterMessage.ViewHold
(message.accountColor == null || !ActivityBilling.isPro(context)
? colorSeparator : message.accountColor);
if (account_color == 2)
if (account_color == 2 &&
!Objects.equals(ivBadge.getTag(), colorBackground)) {
ivBadge.setTag(colorBackground);
((GradientDrawable) ivBadge.getDrawable().mutate()).setColor(colorBackground);
}
ivBadge.setVisibility(account_color == 2 ? View.VISIBLE : View.GONE);
if (account_color == 1 &&
!Objects.equals(vwColor.getTag() == null, colorBackground)) {
!Objects.equals(vwColor.getTag(), colorBackground)) {
vwColor.setTag(colorBackground);
vwColor.setBackgroundColor(colorBackground);
}