From 7811620eb809fb9c2eb0c015e7c1fc6d17dc05ac Mon Sep 17 00:00:00 2001 From: Koni Marti Date: Thu, 24 Feb 2022 00:41:13 +0100 Subject: threading: implement on-the-fly message threading implement message threading on the message store level using the jwz algorithm. Build threads on-the-fly when new message headers arrive. Use the references header to create the threads and the in-reply-to header as a fall-back option in case no references header is present. Does not run when the worker provides its own threading (e.g. imap server threads). Include only those message headers that have been fetched and are stored in the message store. References: https://www.jwz.org/doc/threading.html Signed-off-by: Koni Marti Tested-by: Inwit Tested-by: akspecs Acked-by: Robin Jarry --- widgets/msglist.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'widgets/msglist.go') diff --git a/widgets/msglist.go b/widgets/msglist.go index 6163d0e5..50ce24ee 100644 --- a/widgets/msglist.go +++ b/widgets/msglist.go @@ -89,7 +89,7 @@ func (ml *MessageList) Draw(ctx *ui.Context) { row int = 0 ) - if ml.aerc.SelectedAccount().UiConfig().ThreadingEnabled { + if ml.aerc.SelectedAccount().UiConfig().ThreadingEnabled || store.BuildThreads() { threads := store.Threads counter := len(store.Uids()) -- cgit