GUI: Code cleanup and small issue fixes

This commit is contained in:
aryanrawlani28 2020-05-18 23:46:20 +05:30 committed by Eugene Sandulenko
parent c7469a1145
commit d968665110
4 changed files with 11 additions and 20 deletions

View file

@ -142,8 +142,11 @@ void ScrollContainerWidget::reflowLayout() {
void ScrollContainerWidget::drawWidget() {
// GUI TODO: Recheck what the below line does.
if (this->_name.contains("GameOptions") || this->_name.contains("GlobalOptions"))
_x = g_system->getOverlayWidth() - _w - _x;
if (g_gui.useRTL()) {
if (this->_name.contains("GameOptions") || this->_name.contains("GlobalOptions")) {
_x = g_system->getOverlayWidth() - _x - _w + g_gui.getOverlayOffset();
}
}
g_gui.theme()->drawWidgetBackground(Common::Rect(_x, _y, _x + _w, _y + getHeight()), _backgroundType);
}