Fixed: checkCoords needs XReal to be same as in updateCoords

--HG--
branch : develop
hg/compatibility-develop
Nimetu 6 years ago
parent c2ffa714d2
commit 8ef8b2d62d

@ -1407,6 +1407,9 @@ namespace NLGUI
// ------------------------------------------------------------------------------------------------ // ------------------------------------------------------------------------------------------------
void CInterfaceGroup::checkCoords() void CInterfaceGroup::checkCoords()
{ {
// Make XReal same as in updateCoords() as some elements (CViewText) depends on it
_XReal += _MarginLeft;
//update all children elements //update all children elements
vector<CViewBase*>::const_iterator ite; vector<CViewBase*>::const_iterator ite;
for (ite = _EltOrder.begin() ; ite != _EltOrder.end(); ite++) for (ite = _EltOrder.begin() ; ite != _EltOrder.end(); ite++)
@ -1415,7 +1418,9 @@ namespace NLGUI
if(pIE->getActive()) if(pIE->getActive())
pIE->checkCoords(); pIE->checkCoords();
} }
executeLuaScriptOnDraw();
_XReal -= _MarginLeft;
executeLuaScriptOnDraw();
} }
// ------------------------------------------------------------------------------------------------ // ------------------------------------------------------------------------------------------------

Loading…
Cancel
Save