mirror of
https://github.com/SchildiChat/SchildiChat-android.git
synced 2025-02-09 08:38:43 +01:00
Revert "Reduce time required before updating read marker"
This reverts commit 922b62f9f5239290838567095e983ce9737ee54a. Change-Id: I32fed90bdfa04d5e3dd7f222a330f84f3476d805
This commit is contained in:
parent
6b060bf1bb
commit
57fee29645
@ -947,12 +947,12 @@ class TimelineViewModel @AssistedInject constructor(
|
||||
}
|
||||
|
||||
private fun observeEventDisplayedActions() {
|
||||
// We are buffering scroll events 200 ms
|
||||
// We are buffering scroll events for half a second
|
||||
// and keep the most recent one to set the read receipt on.
|
||||
|
||||
visibleEventsSource
|
||||
.stream()
|
||||
.chunk(200)
|
||||
.chunk(500)
|
||||
.filter { it.isNotEmpty() }
|
||||
.onEach { actions ->
|
||||
val bufferedMostRecentDisplayedEvent = actions.minByOrNull { it.event.indexOfEvent() }?.event ?: return@onEach
|
||||
|
Loading…
x
Reference in New Issue
Block a user