From 55bcca4a31f29d58f2cc07dc0b17e2fd7da5f590 Mon Sep 17 00:00:00 2001 From: Tim Culverhouse Date: Mon, 25 Sep 2023 09:07:44 -0500 Subject: commands: add :toggle-thread-context command Add a command to toggle the display of an thread-context. Update CHANGELOG. Signed-off-by: Tim Culverhouse Tested-by: Inwit Acked-by: Robin Jarry --- lib/msgstore.go | 8 ++++++++ 1 file changed, 8 insertions(+) (limited to 'lib/msgstore.go') diff --git a/lib/msgstore.go b/lib/msgstore.go index 6186b195..ab48f331 100644 --- a/lib/msgstore.go +++ b/lib/msgstore.go @@ -442,6 +442,14 @@ func (store *MessageStore) ThreadedView() bool { return store.threadedView } +func (store *MessageStore) ToggleThreadContext() { + if !store.threadedView { + return + } + store.threadContext = !store.threadContext + store.Sort(store.sortCriteria, nil) +} + func (store *MessageStore) BuildThreads() bool { return store.buildThreads } -- cgit