mirror of
https://github.com/RetroDECK/ES-DE.git
synced 2024-11-25 15:45:38 +00:00
Fixed an issue where ComponentList elements would not get correctly centered vertically.
This commit is contained in:
parent
0dc6f1e17a
commit
59839546a5
|
@ -448,7 +448,7 @@ void ComponentList::updateElementPosition(const ComponentListRow& row)
|
||||||
const auto comp = row.elements.at(i).component;
|
const auto comp = row.elements.at(i).component;
|
||||||
|
|
||||||
// Center vertically.
|
// Center vertically.
|
||||||
comp->setPosition(x, (rowHeight - comp->getSize().y) / 2.0f + yOffset);
|
comp->setPosition(x, std::round((rowHeight - comp->getSize().y) / 2.0f + yOffset));
|
||||||
x += comp->getSize().x;
|
x += comp->getSize().x;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue