mirror of
https://github.com/meshtastic/Meshtastic-Android.git
synced 2026-04-20 22:23:37 +00:00
feat: Add "Mark all as read" and unread message count indicators (#4720)
This commit is contained in:
parent
6a1a612c38
commit
b0258d0cf1
10 changed files with 131 additions and 26 deletions
|
|
@ -49,6 +49,9 @@ interface PacketRepository {
|
|||
/** Returns the count of unread messages in a conversation. */
|
||||
suspend fun getUnreadCount(contact: String): Int
|
||||
|
||||
/** Reactive flow of the unread message count in a conversation. */
|
||||
fun getUnreadCountFlow(contact: String): Flow<Int>
|
||||
|
||||
/** Reactive flow of the UUID of the first unread message in a conversation. */
|
||||
fun getFirstUnreadMessageUuid(contact: String): Flow<Long?>
|
||||
|
||||
|
|
@ -61,6 +64,9 @@ interface PacketRepository {
|
|||
/** Clears the unread status for messages in a conversation up to the given timestamp. */
|
||||
suspend fun clearUnreadCount(contact: String, timestamp: Long)
|
||||
|
||||
/** Clears the unread status for all messages across all conversations. */
|
||||
suspend fun clearAllUnreadCounts()
|
||||
|
||||
/** Updates the identifier of the last read message in a conversation. */
|
||||
suspend fun updateLastReadMessage(contact: String, messageUuid: Long, lastReadTimestamp: Long)
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue