some test with solving space issues on small resolutions
This commit is contained in:
parent
2e3713840f
commit
f6b6526681
@ -76,7 +76,7 @@
|
||||
<!-- Race options box -->
|
||||
<box width="100%" height="43%" layout="vertical-row">
|
||||
<div width="100%" height="fit" layout="horizontal-row" >
|
||||
<div proportion="1" height="fit" layout="horizontal-row">
|
||||
<div proportion="3" height="fit" layout="horizontal-row">
|
||||
<spinner id="target-type-spinner" width="100%" min_value="1" max_value="10" align="center"
|
||||
wrap_around="true" />
|
||||
</div>
|
||||
|
@ -176,6 +176,22 @@ bool Widget::deleteChild(const char* id)
|
||||
return false;
|
||||
}
|
||||
|
||||
bool Widget::collapse()
|
||||
{
|
||||
//const int count = m_children.size();
|
||||
//for (int n = 0; n < count; n++)
|
||||
//{
|
||||
// m_children.erase(n);
|
||||
//}
|
||||
//m_element = NULL;
|
||||
|
||||
auto parent = m_element->getParent();
|
||||
|
||||
parent->removeChild(m_element);
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
// -----------------------------------------------------------------------------
|
||||
namespace GUIEngine
|
||||
{
|
||||
@ -342,6 +358,18 @@ void Widget::setVisible(bool visible)
|
||||
}
|
||||
}
|
||||
|
||||
// -----------------------------------------------------------------------------
|
||||
|
||||
void Widget::setCollapsed(bool collapsed)
|
||||
{
|
||||
if (m_element != NULL)
|
||||
{
|
||||
m_element->setEnabled(!collapsed);
|
||||
}
|
||||
//m_is_visible = collapsed;
|
||||
}
|
||||
|
||||
|
||||
// -----------------------------------------------------------------------------
|
||||
|
||||
void Widget::moveIrrlichtElement()
|
||||
|
@ -344,6 +344,10 @@ namespace GUIEngine
|
||||
*/
|
||||
virtual void setVisible(bool visible);
|
||||
|
||||
virtual bool collapse();
|
||||
|
||||
virtual void setCollapsed(bool collapsed);
|
||||
|
||||
/** Returns if the element is visible. */
|
||||
bool isVisible() const;
|
||||
|
||||
|
@ -175,6 +175,11 @@ void TrackInfoScreen::init()
|
||||
m_target_value_spinner->setValue(UserConfigParams::m_num_goals);
|
||||
}
|
||||
}
|
||||
//else
|
||||
/* {
|
||||
m_target_type_spinner->collapse();
|
||||
m_target_type_label->collapse();
|
||||
}*/
|
||||
|
||||
// Lap count m_lap_spinner
|
||||
// -----------------------
|
||||
|
Loading…
Reference in New Issue
Block a user