initial refactor of all column widgets to standard interface

This commit is contained in:
Bradley Cicenas
2019-06-08 21:34:43 +00:00
parent 9bcf2c2c7a
commit 8427b0c81d
9 changed files with 198 additions and 178 deletions

View File

@@ -55,11 +55,13 @@ func (e *Single) Down() {
}
func (e *Single) SetWidth(w int) { e.Width = w }
func (e *Single) SetMeta(k, v string) {
if k == "[ENV-VAR]" {
e.Env.Set(k, v)
} else {
e.Info.Set(k, v)
func (e *Single) SetMeta(m models.Meta) {
for k, v := range m {
if k == "[ENV-VAR]" {
e.Env.Set(k, v)
} else {
e.Info.Set(k, v)
}
}
}