Revert layout manager changes as it breaks addon screen
This commit is contained in:
parent
8582258cae
commit
949752451c
@ -247,8 +247,7 @@ void LayoutManager::readCoords(Widget* self)
|
||||
//Add padding to <box> elements
|
||||
if (self->getType() == WTYPE_DIV && self->m_show_bounding_box)
|
||||
{
|
||||
int padding = std::min(irr_driver->getActualScreenSize().Height,
|
||||
irr_driver->getActualScreenSize().Width) / 36.0f;
|
||||
int padding = GUIEngine::getFontHeight() / 2;
|
||||
if (self->m_properties[PROP_DIV_PADDING].length() > 0)
|
||||
padding = atoi(self->m_properties[PROP_DIV_PADDING].c_str());
|
||||
child_max_height += padding * 2;
|
||||
@ -323,8 +322,7 @@ void LayoutManager::applyCoords(Widget* self, AbstractTopLevelContainer* topLeve
|
||||
|
||||
if (parent != NULL && parent->getType() == WTYPE_DIV && parent->m_show_bounding_box)
|
||||
{
|
||||
int padding = std::min(irr_driver->getActualScreenSize().Height,
|
||||
irr_driver->getActualScreenSize().Width) / 36.0f;
|
||||
int padding = GUIEngine::getFontHeight() / 2;
|
||||
if (parent->m_properties[PROP_DIV_PADDING].length() > 0)
|
||||
padding = atoi(parent->m_properties[PROP_DIV_PADDING].c_str());
|
||||
|
||||
@ -450,8 +448,7 @@ void LayoutManager::doCalculateLayout(PtrVector<Widget>& widgets, AbstractTopLev
|
||||
|
||||
if (parent != NULL && parent->getType() == WTYPE_DIV && parent->m_show_bounding_box)
|
||||
{
|
||||
int padding = std::min(irr_driver->getActualScreenSize().Height,
|
||||
irr_driver->getActualScreenSize().Width) / 36.0f;
|
||||
int padding = GUIEngine::getFontHeight() / 2;
|
||||
if (parent->m_properties[PROP_DIV_PADDING].length() > 0)
|
||||
padding = atoi(parent->m_properties[PROP_DIV_PADDING].c_str());
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user