aboutsummaryrefslogtreecommitdiffstats
path: root/widgets
diff options
context:
space:
mode:
Diffstat (limited to 'widgets')
-rw-r--r--widgets/account.go2
-rw-r--r--widgets/dirlist.go6
2 files changed, 4 insertions, 4 deletions
diff --git a/widgets/account.go b/widgets/account.go
index ad9d200a..6449aeba 100644
--- a/widgets/account.go
+++ b/widgets/account.go
@@ -308,7 +308,7 @@ func (acct *AccountView) onMessage(msg types.WorkerMessage) {
acct.updateSplitView,
)
store.SetMarker(marker.New(store))
- acct.dirlist.SetMsgStore(msg.Dir.Name, store)
+ acct.dirlist.SetMsgStore(msg.Dir, store)
case *types.DirectoryInfo:
if store, ok := acct.dirlist.MsgStore(msg.Info.Name); ok {
store.Update(msg)
diff --git a/widgets/dirlist.go b/widgets/dirlist.go
index a548b7b7..85cf4112 100644
--- a/widgets/dirlist.go
+++ b/widgets/dirlist.go
@@ -39,7 +39,7 @@ type DirectoryLister interface {
SelectedMsgStore() (*lib.MessageStore, bool)
MsgStore(string) (*lib.MessageStore, bool)
- SetMsgStore(string, *lib.MessageStore)
+ SetMsgStore(*models.Directory, *lib.MessageStore)
FilterDirs([]string, []string, bool) []string
GetRUECount(string) (int, int, int)
@@ -478,8 +478,8 @@ func (dirlist *DirectoryList) MsgStore(name string) (*lib.MessageStore, bool) {
return dirlist.store.MessageStore(name)
}
-func (dirlist *DirectoryList) SetMsgStore(name string, msgStore *lib.MessageStore) {
- dirlist.store.SetMessageStore(name, msgStore)
+func (dirlist *DirectoryList) SetMsgStore(dir *models.Directory, msgStore *lib.MessageStore) {
+ dirlist.store.SetMessageStore(dir, msgStore)
msgStore.OnUpdateDirs(func() {
dirlist.Invalidate()
})