mobile: decrease mark read delay (#1085)

This commit is contained in:
JRoberts
2022-09-21 17:39:29 +04:00
committed by GitHub
parent 9442656bbe
commit 59b4ce2474
2 changed files with 2 additions and 2 deletions

View File

@@ -569,7 +569,7 @@ fun BoxWithConstraintsScope.ChatItemsList(
if (cItem.isRcvNew) {
LaunchedEffect(cItem.id) {
scope.launch {
delay(750)
delay(600)
markRead(CC.ItemRange(cItem.id, cItem.id), null)
}
}

View File

@@ -215,7 +215,7 @@ struct ChatView: View {
itemsInView.insert(ci.viewId)
loadChatItems(cInfo, ci, proxy)
if ci.isRcvNew() {
DispatchQueue.main.asyncAfter(deadline: .now() + 0.75) {
DispatchQueue.main.asyncAfter(deadline: .now() + 0.6) {
if chatModel.chatId == cInfo.id && itemsInView.contains(ci.viewId) {
Task {
await apiMarkChatItemRead(cInfo, ci)