aboutsummaryrefslogtreecommitdiffstats
path: root/commands/account
diff options
context:
space:
mode:
authorKoni Marti <koni.marti@gmail.com>2022-10-03 23:56:06 +0200
committerRobin Jarry <robin@jarry.cc>2022-10-04 09:43:58 +0200
commite4d418eed15858d6dcae70e73b8a6c3e4439b5bc (patch)
tree58f1bc0b216965415074fa77c6503594771ea080 /commands/account
parent4c371170c57d39399a924bd4d27d67226a9a7f39 (diff)
downloadaerc-e4d418eed15858d6dcae70e73b8a6c3e4439b5bc.tar.gz
viewer: option to not mark message as seen
Add option to open a message in the message viewer without setting the seen flag. Enables the message viewer to be used as a preview pane without changing the message flags unintentionally. Before, the message viewer would set the seen flag by default. The IMAP backend will now always fetch the message body with the peek option enabled (same as we fetch the headers). An "auto-mark-read" option is added to the ui config which is set to true by default. If set the false, the seen flag is not set by the message viewer. Co-authored-by: "James Cook" <falsifian@falsifian.org> Signed-off-by: Koni Marti <koni.marti@gmail.com> Acked-by: Robin Jarry <robin@jarry.cc>
Diffstat (limited to 'commands/account')
-rw-r--r--commands/account/view.go3
1 files changed, 2 insertions, 1 deletions
diff --git a/commands/account/view.go b/commands/account/view.go
index 8537d331..be8b45e4 100644
--- a/commands/account/view.go
+++ b/commands/account/view.go
@@ -45,7 +45,8 @@ func (ViewMessage) Execute(aerc *widgets.Aerc, args []string) error {
aerc.PushError(msg.Error.Error())
return nil
}
- lib.NewMessageStoreView(msg, store, aerc.Crypto, aerc.DecryptKeys,
+ lib.NewMessageStoreView(msg, acct.UiConfig().AutoMarkRead,
+ store, aerc.Crypto, aerc.DecryptKeys,
func(view lib.MessageView, err error) {
if err != nil {
aerc.PushError(err.Error())