mirror of
https://github.com/RetroDECK/ES-DE.git
synced 2025-01-31 04:25:40 +00:00
reformat HelpComponent if-else.
This commit is contained in:
parent
eb4a8d5fae
commit
c1d7f37a07
|
@ -204,18 +204,14 @@ void HelpComponent::updateGrid()
|
|||
icon->setResize(0, height);
|
||||
icons.push_back(icon);
|
||||
|
||||
// Format label according to theme style.
|
||||
// Apply text style and color from the theme to the label and add it to the label list.
|
||||
std::string lblInput = it->second;
|
||||
if (mStyle.textStyle == "lowercase") {
|
||||
if (mStyle.textStyle == "lowercase")
|
||||
lblInput = Utils::String::toLower(lblInput);
|
||||
}
|
||||
else if (mStyle.textStyle == "camelcase") {
|
||||
else if (mStyle.textStyle == "camelcase")
|
||||
lblInput = Utils::String::toCamelCase(lblInput);
|
||||
}
|
||||
else {
|
||||
else
|
||||
lblInput = Utils::String::toUpper(lblInput);
|
||||
}
|
||||
|
||||
auto lbl = std::make_shared<TextComponent>(
|
||||
mWindow, lblInput, font, isDimmed ? mStyle.textColorDimmed : mStyle.textColor);
|
||||
labels.push_back(lbl);
|
||||
|
|
Loading…
Reference in a new issue