mirror of
https://github.com/signalapp/Signal-Android.git
synced 2025-12-24 04:58:45 +00:00
Fix issue where some threads were invisibly unread.
Problem 1: We weren't marking threads read when we shared into them. Problem 2: We hid the unread status of threads whose last message was outgoing. This addresses both. It's possible that 'fixing' problem 2 could result in more threads being marked as read, but really that should just make us aware so we can properly mark the thread as read.
This commit is contained in:
@@ -462,7 +462,7 @@ public final class ConversationListItem extends ConstraintLayout implements Bind
|
||||
}
|
||||
|
||||
private void setUnreadIndicator(ThreadRecord thread) {
|
||||
if ((thread.isOutgoing() && !thread.isForcedUnread()) || thread.isRead()) {
|
||||
if (thread.isRead()) {
|
||||
unreadIndicator.setVisibility(View.GONE);
|
||||
return;
|
||||
}
|
||||
|
||||
@@ -156,6 +156,10 @@ public final class MultiShareSender {
|
||||
results.add(new MultiShareSendResult(recipientSearchKey, MultiShareSendResult.Type.SUCCESS));
|
||||
}
|
||||
|
||||
if (!recipientSearchKey.isStory()) {
|
||||
SignalDatabase.threads().setRead(threadId, true);
|
||||
}
|
||||
|
||||
// XXX We must do this to avoid sending out messages to the same recipient with the same
|
||||
// sentTimestamp. If we do this, they'll be considered dupes by the receiver.
|
||||
ThreadUtil.sleep(5);
|
||||
|
||||
Reference in New Issue
Block a user