aboutsummaryrefslogtreecommitdiffstats
path: root/widgets/aerc.go
diff options
context:
space:
mode:
authorKoni Marti <koni.marti@gmail.com>2022-03-24 21:42:05 +0100
committerRobin Jarry <robin@jarry.cc>2022-03-25 13:07:14 +0100
commitaf2a70983c8d9a940a064c17057d42d92d717883 (patch)
treeaa0fad9ef6828d86f5e56cd790b4f8030623129f /widgets/aerc.go
parent73b64f2bf94a5be27e1feccb87cc95c4b7b8a08b (diff)
downloadaerc-af2a70983c8d9a940a064c17057d42d92d717883.tar.gz
statusline: improve status line updating
Update statusline only for the selected account (to prevent other updates from different accounts to interfere). Update status when jumping/selecting/closing tabs. Fixes cosmetic regressions introduced by commit feecc09b73e2 ("statusline: make statusline folder-specific"). Signed-off-by: Koni Marti <koni.marti@gmail.com> Acked-by: Robin Jarry <robin@jarry.cc>
Diffstat (limited to 'widgets/aerc.go')
-rw-r--r--widgets/aerc.go3
1 files changed, 3 insertions, 0 deletions
diff --git a/widgets/aerc.go b/widgets/aerc.go
index db447e47..94e67542 100644
--- a/widgets/aerc.go
+++ b/widgets/aerc.go
@@ -343,6 +343,7 @@ func (aerc *Aerc) NewTab(clickable ui.Drawable, name string) *ui.Tab {
func (aerc *Aerc) RemoveTab(tab ui.Drawable) {
aerc.tabs.Remove(tab)
+ aerc.UpdateStatus()
}
func (aerc *Aerc) ReplaceTab(tabSrc ui.Drawable, tabTarget ui.Drawable, name string) {
@@ -373,6 +374,7 @@ func (aerc *Aerc) SelectTab(name string) bool {
for i, tab := range aerc.tabs.Tabs {
if tab.Name == name {
aerc.tabs.Select(i)
+ aerc.UpdateStatus()
return true
}
}
@@ -383,6 +385,7 @@ func (aerc *Aerc) SelectTabIndex(index int) bool {
for i := range aerc.tabs.Tabs {
if i == index {
aerc.tabs.Select(i)
+ aerc.UpdateStatus()
return true
}
}