Parse Hidden and Example fields
This commit is contained in:
parent
a7a3e8b675
commit
d82e802563
@ -191,11 +191,23 @@ func parseThemeIndex (reader io.Reader) (theme Theme, parents []string, err erro
|
||||
theme.Directories, err = parseDirectories(entry, file)
|
||||
if err != nil { return Theme { }, nil, err }
|
||||
|
||||
// ScaledDirectories
|
||||
// ScaledDirectories (optional)
|
||||
if entry, ok := iconThemeGroup["ScaledDirectories"]; ok {
|
||||
theme.ScaledDirectories, err = parseDirectories(entry, file)
|
||||
if err != nil { return Theme { }, nil, err }
|
||||
}
|
||||
|
||||
// Hidden (optional)
|
||||
if entry, ok := iconThemeGroup["Hidden"]; ok {
|
||||
theme.Hidden, err = keyValue.ParseBoolean(entry.Value)
|
||||
if err != nil { return Theme { }, nil, err }
|
||||
}
|
||||
|
||||
// Example (optional)
|
||||
if entry, ok := iconThemeGroup["Example"]; ok {
|
||||
theme.Example, err = keyValue.ParseString(entry.Value)
|
||||
if err != nil { return Theme { }, nil, err }
|
||||
}
|
||||
|
||||
return theme, parents, nil
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user