When the user scrolls to a specific point in the timeline view, we should send read receipts such that the server knows the user has read up to that point.
The type of read receipt we send will vary based on the scroll position:
Send a regular Read receipt when a message is first scrolled into the bottom of the timeline view
Send a FullyRead receipt when a message is scrolled out of view above the top of the timeline view
This won't necessarily cover all cases, for example it excludes the last set of messages at the bottom of the timeline, which cannot be scrolled up out of view. We can also send this FullyRead receipt upon other actions, e.g., when the message is displayed on screen for more than 5 or 10 seconds.
When the user scrolls to a specific point in the timeline view, we should send read receipts such that the server knows the user has read up to that point.
Relevant Matrix SDK functions
The function we most likely want to use is
send_multiple_receipts()
. There is also asend_single_receipt()
function, though I'm not sure when we'd prefer that one.The type of read receipt we send will vary based on the scroll position:
Read
receipt when a message is first scrolled into the bottom of the timeline viewFullyRead
receipt when a message is scrolled out of view above the top of the timeline viewFullyRead
receipt upon other actions, e.g., when the message is displayed on screen for more than 5 or 10 seconds.