CHANGED: Implemented property setting for CGroupTab.

This commit is contained in:
dfighter1985 2012-08-07 02:32:12 +02:00
parent ede9c82fec
commit 08dec79e72
2 changed files with 27 additions and 0 deletions

View file

@ -48,6 +48,7 @@ namespace NLGUI
CGroupTab(const TCtorParam &param); CGroupTab(const TCtorParam &param);
std::string getProperty( const std::string &name ) const; std::string getProperty( const std::string &name ) const;
void setProperty( const std::string &name, const std::string &value );
virtual bool parse (xmlNodePtr cur, CInterfaceGroup *parentGroup); virtual bool parse (xmlNodePtr cur, CInterfaceGroup *parentGroup);
virtual void updateCoords (); virtual void updateCoords ();

View file

@ -62,6 +62,32 @@ namespace NLGUI
return CInterfaceGroup::getProperty( name ); return CInterfaceGroup::getProperty( name );
} }
void CGroupTab::setProperty( const std::string &name, const std::string &value )
{
if( name == "hide_out_tabs" )
{
bool b;
if( fromString( value, b ) )
_HideOutTabs = b;
return;
}
else
if( name == "onchange" )
{
_AHOnChange = value;
return;
}
else
if( name == "onchange_params" )
{
_ParamsOnChange = value;
return;
}
else
CInterfaceGroup::setProperty( name, value );
}
// *************************************************************************** // ***************************************************************************
bool CGroupTab::parse (xmlNodePtr cur, CInterfaceGroup *parentGroup) bool CGroupTab::parse (xmlNodePtr cur, CInterfaceGroup *parentGroup)
{ {