mirror of
https://github.com/RetroDECK/ES-DE.git
synced 2024-11-25 23:55:38 +00:00
Added center theme option for TextListComponent.
This commit is contained in:
parent
997751f56a
commit
b7b2998720
|
@ -243,6 +243,7 @@ Reference
|
|||
* `fontPath` - type: PATH.
|
||||
* `fontSize` - type: FLOAT.
|
||||
* `scrollSound` - type: PATH.
|
||||
* `center` - type: BOOLEAN.
|
||||
|
||||
#### container
|
||||
* `pos` - type: NORMALIZED_PAIR.
|
||||
|
|
|
@ -34,7 +34,8 @@ std::map< std::string, std::map<std::string, ThemeData::ElementPropertyType> > T
|
|||
("secondaryColor", COLOR)
|
||||
("fontPath", PATH)
|
||||
("fontSize", FLOAT)
|
||||
("scrollSound", PATH))
|
||||
("scrollSound", PATH)
|
||||
("center", BOOLEAN))
|
||||
("container", boost::assign::map_list_of
|
||||
("pos", NORMALIZED_PAIR)
|
||||
("size", NORMALIZED_PAIR))
|
||||
|
|
|
@ -433,6 +433,9 @@ void TextListComponent<T>::applyTheme(const std::shared_ptr<ThemeData>& theme, c
|
|||
|
||||
if(properties & SOUND && elem->has("scrollSound"))
|
||||
setSound(Sound::get(elem->get<std::string>("scrollSound")));
|
||||
|
||||
if(properties & CENTER && elem->has("center"))
|
||||
mCentered = elem->get<bool>("center");
|
||||
}
|
||||
|
||||
#endif
|
||||
|
|
Loading…
Reference in a new issue