From 66fd9526de9cd8fb45ce50ba2a4d2935b98c958e Mon Sep 17 00:00:00 2001 From: dfighter1985 Date: Wed, 1 Aug 2012 05:58:10 +0200 Subject: [PATCH] CHANGED: #1471 Implemented property querying for CGroupHeader. --- code/nel/include/nel/gui/group_header.h | 3 +++ code/nel/src/gui/group_header.cpp | 10 ++++++++++ .../plugins/gui_editor/widgets/GroupHeader.xml | 17 +++++++++++++++++ 3 files changed, 30 insertions(+) create mode 100644 code/nel/tools/3d/object_viewer_qt/src/plugins/gui_editor/widgets/GroupHeader.xml diff --git a/code/nel/include/nel/gui/group_header.h b/code/nel/include/nel/gui/group_header.h index 81d5d20be..5988a06f5 100644 --- a/code/nel/include/nel/gui/group_header.h +++ b/code/nel/include/nel/gui/group_header.h @@ -41,6 +41,9 @@ namespace NLGUI REFLECT_EXPORT_END CGroupHeader(const TCtorParam ¶m); + + std::string getProperty( const std::string &name ) const; + // from CInterfaceGroup virtual bool parse(xmlNodePtr cur, CInterfaceGroup * parentGroup); sint32 getHeaderMaxSize() const { return _HeaderMaxSize; } diff --git a/code/nel/src/gui/group_header.cpp b/code/nel/src/gui/group_header.cpp index 48ae85776..961e877de 100644 --- a/code/nel/src/gui/group_header.cpp +++ b/code/nel/src/gui/group_header.cpp @@ -215,6 +215,16 @@ namespace NLGUI return 0; } + std::string CGroupHeader::getProperty( const std::string &name ) const + { + if( name == "header_max_size" ) + { + return toString( _HeaderMaxSize ); + } + else + return CGroupList::getProperty( name ); + } + // ***************************************************************************************************************** bool CGroupHeader::parse(xmlNodePtr cur, CInterfaceGroup * parentGroup) { diff --git a/code/nel/tools/3d/object_viewer_qt/src/plugins/gui_editor/widgets/GroupHeader.xml b/code/nel/tools/3d/object_viewer_qt/src/plugins/gui_editor/widgets/GroupHeader.xml new file mode 100644 index 000000000..ac8cde50e --- /dev/null +++ b/code/nel/tools/3d/object_viewer_qt/src/plugins/gui_editor/widgets/GroupHeader.xml @@ -0,0 +1,17 @@ + +
+ GroupHeader + CGroupHeader + GroupList + + false + +
+ + + header_max_size + int + 32767 + + +