mirror of
https://port.numenaute.org/aleajactaest/khanat-code-old.git
synced 2024-11-11 17:59:02 +00:00
CHANGED: #1471 Implemented property querying for for CViewTextID.
This commit is contained in:
parent
66f722e9d8
commit
ea1ac7fa6d
3 changed files with 53 additions and 0 deletions
|
@ -91,6 +91,7 @@ namespace NLGUI
|
||||||
|
|
||||||
~CViewTextID();
|
~CViewTextID();
|
||||||
|
|
||||||
|
std::string getProperty( const std::string &name ) const;
|
||||||
virtual bool parse(xmlNodePtr cur, CInterfaceGroup * parentGroup);
|
virtual bool parse(xmlNodePtr cur, CInterfaceGroup * parentGroup);
|
||||||
virtual void checkCoords();
|
virtual void checkCoords();
|
||||||
|
|
||||||
|
|
|
@ -46,6 +46,29 @@ namespace NLGUI
|
||||||
{
|
{
|
||||||
}
|
}
|
||||||
|
|
||||||
|
std::string CViewTextID::getProperty( const std::string &name ) const
|
||||||
|
{
|
||||||
|
if( name == "textid" )
|
||||||
|
{
|
||||||
|
if( _DBTextId.getNodePtr() != NULL )
|
||||||
|
return _DBTextId.getNodePtr()->getFullName();
|
||||||
|
else
|
||||||
|
return NLMISC::toString( _TextId );
|
||||||
|
}
|
||||||
|
else
|
||||||
|
if( name == "dynamic_string" )
|
||||||
|
{
|
||||||
|
return NLMISC::toString( _DynamicString );
|
||||||
|
}
|
||||||
|
else
|
||||||
|
if( name == "format_taged" )
|
||||||
|
{
|
||||||
|
return NLMISC::toString( _IsTextFormatTaged );
|
||||||
|
}
|
||||||
|
else
|
||||||
|
return CViewText::getProperty( name );
|
||||||
|
}
|
||||||
|
|
||||||
// ***************************************************************************
|
// ***************************************************************************
|
||||||
bool CViewTextID::parse(xmlNodePtr cur, CInterfaceGroup * parentGroup)
|
bool CViewTextID::parse(xmlNodePtr cur, CInterfaceGroup * parentGroup)
|
||||||
{
|
{
|
||||||
|
|
|
@ -0,0 +1,29 @@
|
||||||
|
<widget>
|
||||||
|
<header>
|
||||||
|
<name>ViewTextID</name>
|
||||||
|
<guiname>CViewTextID</guiname>
|
||||||
|
<ancestor>ViewText</ancestor>
|
||||||
|
<description></description>
|
||||||
|
<abstract>false</abstract>
|
||||||
|
<icon></icon>
|
||||||
|
</header>
|
||||||
|
<properties>
|
||||||
|
<property>
|
||||||
|
<name>text_id</name>
|
||||||
|
<type>string</type>
|
||||||
|
<default></default>
|
||||||
|
</property>
|
||||||
|
<property>
|
||||||
|
<name>dynamic_string</name>
|
||||||
|
<type>bool</type>
|
||||||
|
<default>true</default>
|
||||||
|
</property>
|
||||||
|
<property>
|
||||||
|
<name>format_taged</name>
|
||||||
|
<type>bool</type>
|
||||||
|
<default>false</default>
|
||||||
|
</property>
|
||||||
|
|
||||||
|
|
||||||
|
</properties>
|
||||||
|
</widget>
|
Loading…
Reference in a new issue