fix: Send read receipt only on focus
This commit is contained in:
parent
1dbff85341
commit
d26e830b17
1 changed files with 2 additions and 1 deletions
|
|
@ -494,7 +494,8 @@ class _ChatState extends State<_Chat> {
|
||||||
if (room.notificationCount != null &&
|
if (room.notificationCount != null &&
|
||||||
room.notificationCount > 0 &&
|
room.notificationCount > 0 &&
|
||||||
timeline != null &&
|
timeline != null &&
|
||||||
timeline.events.isNotEmpty) {
|
timeline.events.isNotEmpty &&
|
||||||
|
Matrix.of(context).webHasFocus) {
|
||||||
room.sendReadReceipt(timeline.events.first.eventId);
|
room.sendReadReceipt(timeline.events.first.eventId);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue