mirror of
https://github.com/eeeXun/GTT.git
synced 2025-05-18 16:50:14 -07:00
refactor: use make to create map
This commit is contained in:
parent
035a92130a
commit
aa7935969e
@ -37,7 +37,7 @@ var (
|
||||
|
||||
func NewTheme(name string, palette map[string]int32) {
|
||||
AllTheme = append(AllTheme, name)
|
||||
themes[name] = map[string]tcell.Color{}
|
||||
themes[name] = make(map[string]tcell.Color)
|
||||
for color, rgb := range palette {
|
||||
themes[name][color] = tcell.NewHexColor(rgb)
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user