open
https://gitlab.synchro.net/main/sbbs/-/work_items/1271
## Summary
Remember the last e-mail message a user viewed, so they can quit the mail reader, go do something else, and come back to continue from that message.
## Current behavior
Sub-boards keep a per-user "last read" pointer, so reading can resume where
it left off. Mail has no equivalent. Each message carries its own read
flag (`MSG_READ`), which the "un-read mail only" reading mode uses, but
that only finds messages never read before: the message a user was on when
they quit has already been marked read. `readmail()` starts at the first message in the list every time, so a user reading through older mail has to find their place again.
## Proposal
* Store the number of the last mail message the user viewed ("your mail"),
per user, alongside the sub-board pointers in `data/user/####.subs`. The
section name needs to be one that cannot also be a sub-board internal
code.
* When the mail reader starts (not in un-read-only mode), begin at that
message if it is still there, or else the next one after it.
* Make it available to JavaScript mail readers, as the sub-board pointers
are, so they can resume the same way.
Possibly also for sent mail, which is read the same way.
Related: #1027 (a user setting to read new or un-read netmail on login).
-- *Authored by Claude (Claude Code), on behalf of @rswindell*
--- SBBSecho 3.38-Linux
* Origin: Vertrauen - [vert/cvs/bbs].synchro.net (1:103/705)