From 194b7e8dea623fd2c1e7d11ac12384c8df8cab8c Mon Sep 17 00:00:00 2001 From: M66B Date: Thu, 9 Aug 2018 05:37:52 +0000 Subject: [PATCH] Fixed showing seen --- .../eu/faircode/email/AdapterMessage.java | 34 +++++++++---------- .../java/eu/faircode/email/EntityFolder.java | 4 --- .../eu/faircode/email/EntityOperation.java | 12 +------ 3 files changed, 18 insertions(+), 32 deletions(-) diff --git a/app/src/main/java/eu/faircode/email/AdapterMessage.java b/app/src/main/java/eu/faircode/email/AdapterMessage.java index 9576070b..0659dc39 100644 --- a/app/src/main/java/eu/faircode/email/AdapterMessage.java +++ b/app/src/main/java/eu/faircode/email/AdapterMessage.java @@ -89,17 +89,16 @@ public class AdapterMessage extends PagedListAdapter 1 ? View.VISIBLE : View.GONE); - } else + } else { tvCount.setText(extra + Helper.localizeFolderName(context, message.folderName)); + tvCount.setVisibility(View.VISIBLE); + } ivAttachments.setVisibility(message.attachments > 0 ? View.VISIBLE : View.GONE); - boolean unseen = (message.thread == null && !outbox ? message.unseen > 0 : !message.seen); - - int typeface = (unseen ? Typeface.BOLD : Typeface.NORMAL); + int typeface = (message.unseen > 0 ? Typeface.BOLD : Typeface.NORMAL); tvFrom.setTypeface(null, typeface); tvTime.setTypeface(null, typeface); tvSubject.setTypeface(null, typeface); tvCount.setTypeface(null, typeface); - int colorUnseen = Helper.resolveColor(context, unseen + int colorUnseen = Helper.resolveColor(context, message.unseen > 0 ? R.attr.colorUnread : android.R.attr.textColorSecondary); tvFrom.setTextColor(colorUnseen); tvTime.setTextColor(colorUnseen); @@ -143,12 +142,13 @@ public class AdapterMessage extends PagedListAdapter