summary refs log tree commit diff stats
path: root/widgets/msglist.go
diff options
context:
space:
mode:
authorPaul Spooren <mail@aparcar.org>2019-08-29 15:30:35 -1000
committerDrew DeVault <sir@cmpwn.com>2019-08-30 10:32:28 +0900
commite4104a867401e383ef2b45f4c449b8b3fa25e69b (patch)
tree74a0ec139b3630e1f9963122d3ffa2809aaf0616 /widgets/msglist.go
parentf13f9a86849ff8b4616aa7b462ed171833e02a95 (diff)
downloadaerc-e4104a867401e383ef2b45f4c449b8b3fa25e69b.tar.gz
Allow custom spinner via config file
Allows to set `ui.spinner=` to a string which is then split by
`ui.spinner-delimiter=` (Default: comma) instead of having a hard coded
animation.

This implementation doesn't use INIs capabilities to split strings as
it trims whitespaces breaking the default animation.

Signed-off-by: Paul Spooren <mail@aparcar.org>
Diffstat (limited to 'widgets/msglist.go')
-rw-r--r--widgets/msglist.go2
1 files changed, 1 insertions, 1 deletions
diff --git a/widgets/msglist.go b/widgets/msglist.go
index df83dbd..a316cf5 100644
--- a/widgets/msglist.go
+++ b/widgets/msglist.go
@@ -59,7 +59,7 @@ func NewMessageList(conf *config.AercConfig, logger *log.Logger) *MessageList {
 	ml := &MessageList{
 		conf:          conf,
 		logger:        logger,
-		spinner:       NewSpinner(),
+		spinner:       NewSpinner(&conf.Ui),
 		isInitalizing: true,
 	}
 	ml.spinner.OnInvalidate(func(_ ui.Drawable) {