From 067ed572a4246076d9aa0d445e310d9ce9eb58a3 Mon Sep 17 00:00:00 2001 From: dfighter1985 Date: Sat, 4 Aug 2012 08:06:09 +0200 Subject: [PATCH] CHANGED: #1471 Implemented property setting for CViewTextIDFormated. --- code/nel/include/nel/gui/view_text_id_formated.h | 1 + code/nel/src/gui/view_text_id_formated.cpp | 12 ++++++++++++ 2 files changed, 13 insertions(+) diff --git a/code/nel/include/nel/gui/view_text_id_formated.h b/code/nel/include/nel/gui/view_text_id_formated.h index 89fa54e54..0965099c0 100644 --- a/code/nel/include/nel/gui/view_text_id_formated.h +++ b/code/nel/include/nel/gui/view_text_id_formated.h @@ -40,6 +40,7 @@ namespace NLGUI {} 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 void checkCoords(); const ucstring &getFormatString() const { return _FormatString; } diff --git a/code/nel/src/gui/view_text_id_formated.cpp b/code/nel/src/gui/view_text_id_formated.cpp index 7d36f7649..715ac152a 100644 --- a/code/nel/src/gui/view_text_id_formated.cpp +++ b/code/nel/src/gui/view_text_id_formated.cpp @@ -36,6 +36,18 @@ namespace NLGUI return CViewTextID::getProperty( name ); } + + void CViewTextIDFormated::setProperty( const std::string &name, const std::string &value ) + { + if( name == "format" ) + { + setFormatString( value ); + return; + } + else + CViewTextID::setProperty( name, value ); + } + // ********************************************************************************* bool CViewTextIDFormated::parse(xmlNodePtr cur,CInterfaceGroup * parentGroup) {