From c7fb1d79c4c86cf30d7740d021fdedfdec55542d Mon Sep 17 00:00:00 2001 From: Greyson Parrelli Date: Tue, 24 Jul 2018 16:33:45 -0400 Subject: [PATCH] Properly show group message header after a date divider. --- src/org/thoughtcrime/securesms/ConversationItem.java | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/src/org/thoughtcrime/securesms/ConversationItem.java b/src/org/thoughtcrime/securesms/ConversationItem.java index 78054f742d..f93b2258f4 100644 --- a/src/org/thoughtcrime/securesms/ConversationItem.java +++ b/src/org/thoughtcrime/securesms/ConversationItem.java @@ -702,7 +702,9 @@ public class ConversationItem extends LinearLayout private void setAuthor(@NonNull MessageRecord current, @NonNull Optional previous, @NonNull Optional next, boolean isGroupThread) { if (isGroupThread && !current.isOutgoing()) { - if (!previous.isPresent() || previous.get().isUpdate() || !current.getRecipient().getAddress().equals(previous.get().getRecipient().getAddress())) { + if (!previous.isPresent() || previous.get().isUpdate() || !current.getRecipient().getAddress().equals(previous.get().getRecipient().getAddress()) || + !DateUtils.isSameDay(previous.get().getTimestamp(), current.getTimestamp())) + { groupSenderHolder.setVisibility(VISIBLE); } else { groupSenderHolder.setVisibility(GONE);