diff options
author | Koni Marti <koni.marti@gmail.com> | 2022-03-24 23:12:16 +0100 |
---|---|---|
committer | Robin Jarry <robin@jarry.cc> | 2022-03-25 13:07:25 +0100 |
commit | fc604b667939bfe52ab8758a9a369e2c63de4dbc (patch) | |
tree | 06f9d7326f8392200868ec91a166523365f57907 /lib/statusline/state.go | |
parent | 20218de913d871390a97aa3b86a03d5d06af50d6 (diff) | |
download | aerc-fc604b667939bfe52ab8758a9a369e2c63de4dbc.tar.gz |
statusline: indicate when sorting is in progress
Indicate when sorting is in progress in the statusline.
Signed-off-by: Koni Marti <koni.marti@gmail.com>
Acked-by: Robin Jarry <robin@jarry.cc>
Diffstat (limited to 'lib/statusline/state.go')
-rw-r--r-- | lib/statusline/state.go | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/lib/statusline/state.go b/lib/statusline/state.go index fe32626a..895bb2c4 100644 --- a/lib/statusline/state.go +++ b/lib/statusline/state.go @@ -109,6 +109,15 @@ func Search(desc string) SetStateFunc { } } +func Sorting(on bool) SetStateFunc { + return func(s *State, folder string) { + s.folderState(folder).Sorting = "" + if on { + s.folderState(folder).Sorting = "sorting" + } + } +} + func Threading(on bool) SetStateFunc { return func(s *State, folder string) { s.folderState(folder).Threading = "" |