Main Page | Class Hierarchy | Class List | File List | Class Members | Related Pages

CGUIRadioGroup Class Reference

RadioGroup Control class. More...

#include <GUI.h>

Inheritance diagram for CGUIRadioGroup:

CGUIStatic CGUIElement CXMLResource CDoubleList< CGUIElement * > CResource CEntity CGUITabControl List of all members.

Public Member Functions

virtual void Initialize ()
virtual int Create (CGUIElement *pParent, tRect WidgetRect, CCustomFont *pFont=NULL, CTexture *pTexture=NULL, CMaterial *pMaterial=NULL, bool bBorder=false)
virtual void Draw ()
virtual int LoadXML (TiXmlNode *pDataNode, CString strFilename)
virtual int SaveXML (TiXmlNode *pDataNode, CString strFilename)
virtual void SetCurSel (int iSelection)
int GetCurSel ()
virtual CGUIElementInsertItem (CString &strItemText, UINT uiInsertAfter=0)
virtual bool PropertyChanging (const void *pvProperty, void *pvNewValue)
virtual void GetProperties (EPropList &PropList)
virtual void ProcessMessage (tGUIMessage &Message)
virtual bool IsOfType (eEntityType eType)

Protected Attributes

int m_iCurBtnSel

Detailed Description

RadioGroup Control class.

This class is a collection of buttons that are part of
this radio group.

Definition at line 1978 of file GUI.h.


Member Function Documentation

int CGUIRadioGroup::Create CGUIElement pParent,
tRect  WidgetRect,
CCustomFont pFont = NULL,
CTexture pTexture = NULL,
CMaterial pMaterial = NULL,
bool  bBorder = false
[virtual]
 

Method details:

Parameters:
pParent - Pointer to parent widget
WidgetRect - Rectangle for this widget
pFont - Pointer to CCustomFont derived font for the widget to draw the text
pTexture - Pointer to texture
pMaterial - Pointer to material
bBorder - does this widget has a border?
Returns:
1 if sucessful, 0 if not

Reimplemented from CGUIStatic.

Definition at line 23 of file GUIRadioGroup.cpp.

References CGUIStatic::Create().

void CGUIRadioGroup::Draw  )  [virtual]
 

Method details: Draws the widget

Reimplemented from CGUIStatic.

Reimplemented in CGUITabControl.

Definition at line 78 of file GUIRadioGroup.cpp.

References CDoubleList< CGUIElement * >::begin(), CGUIElement::Draw(), CGUIStatic::Draw(), CGUIElement::GetType(), CGUIElement::HideSiblings(), CDoubleList< CGUIElement * >::next(), CDoubleList< CGUIElement * >::set_ptr(), CGUIElement::ShowSiblings(), and CGUIElement::Visible().

int CGUIRadioGroup::GetCurSel  ) 
 

Method details:

Returns:
Index of current selection
Definition at line 160 of file GUIRadioGroup.cpp.

References m_iCurBtnSel.

Referenced by CGUITabControl::LoadXML(), and CGUITabControl::ProcessMessage().

void CGUIRadioGroup::GetProperties EPropList &  PropList  )  [virtual]
 

Method details:

Parameters:
PropList - Const. reference to the property list

Reimplemented from CGUIStatic.

Reimplemented in CGUITabControl.

Definition at line 215 of file GUIRadioGroup.cpp.

References CDoubleList< CGUIElement * >::begin(), CGUIStatic::GetProperties(), CGUIElement::GetType(), m_iCurBtnSel, CDoubleList< CGUIElement * >::next(), and CDoubleList< CGUIElement * >::set_ptr().

Referenced by CGUITabControl::GetProperties().

void CGUIRadioGroup::Initialize  )  [virtual]
 

Method details: Initializes GUI Border' variables

Reimplemented from CGUIStatic.

Reimplemented in CGUITabControl.

Definition at line 15 of file GUIRadioGroup.cpp.

References m_iCurBtnSel, and CGUIElement::SetType().

CGUIElement * CGUIRadioGroup::InsertItem CString &  strItemText,
UINT  uiInsertAfter = 0
[virtual]
 

Method details:

Parameters:
strItemText - Text for the new item entry
uiInsertAfter - Insert new entry after item specified by index this parameter
Definition at line 165 of file GUIRadioGroup.cpp.

References CGUIButton::Create(), CGUIElement::GetRect(), CGUIButton::LoadXML(), CDoubleList< CGUIElement * >::push_back(), CGUIStatic::Resize(), and CGUIStatic::SetText().

Referenced by CGUITabControl::PropertyChanging(), and PropertyChanging().

bool CGUIRadioGroup::IsOfType eEntityType  eType  )  [virtual]
 

Method details: This is an implementation of Custom RTTI

Reimplemented from CGUIStatic.

Reimplemented in CGUITabControl.

Definition at line 187 of file GUIRadioGroup.cpp.

References CGUIStatic::IsOfType().

Referenced by CGUITabControl::IsOfType().

int CGUIRadioGroup::LoadXML TiXmlNode pDataNode,
CString  strFilename
[virtual]
 

Method details:

Parameters:
pDataNode - Pointer to XML Node that holds data for this widget
strFilename - String containing filename where the data for the widget is stored

Reimplemented from CGUIStatic.

Reimplemented in CGUITabControl.

Definition at line 28 of file GUIRadioGroup.cpp.

References TiXmlElement::Attribute(), CEntity::GetID(), CEntity::GetName(), CSingleton< CGlobalLogger >::GetSingleton(), CGUIStatic::LoadXML(), SetCurSel(), and CLogger::Write().

Referenced by CGUITabControl::LoadXML().

void CGUIRadioGroup::ProcessMessage tGUIMessage Message  )  [virtual]
 

Method details:

Parameters:
Message - Const. Reference to the message structure that is to be processed.

Reimplemented from CGUIElement.

Reimplemented in CGUITabControl.

Definition at line 129 of file GUIRadioGroup.cpp.

References CDoubleList< CGUIElement * >::begin(), CGUIElement::GetType(), CDoubleList< CGUIElement * >::next(), tGUIMessage::pSender, CDoubleList< CGUIElement * >::set_ptr(), and SetCurSel().

bool CGUIRadioGroup::PropertyChanging const void *  pvProperty,
void *  pvNewValue
[virtual]
 

Method details:

Parameters:
pvProperty - Pointer to the property
pvNewValue - Pointer to the new value

Reimplemented from CGUIStatic.

Reimplemented in CGUITabControl.

Definition at line 195 of file GUIRadioGroup.cpp.

References InsertItem(), m_iCurBtnSel, CGUIStatic::PropertyChanging(), and SetCurSel().

Referenced by CGUITabControl::PropertyChanging().

int CGUIRadioGroup::SaveXML TiXmlNode pDataNode,
CString  strFilename
[virtual]
 

Method details:

Parameters:
pDataNode - Pointer to XML Node that will be the parent hold the data for this widget
strFilename - String containing filename where the data for the widget is stored

Reimplemented from CGUIStatic.

Reimplemented in CGUITabControl.

Definition at line 54 of file GUIRadioGroup.cpp.

References m_iCurBtnSel, CGUIElement::SaveXML(), TiXmlElement::SetAttribute(), and TiXmlNode::ToElement().

Referenced by CGUITabControl::SaveXML().

void CGUIRadioGroup::SetCurSel int  iSelection  )  [virtual]
 

Method details:

Parameters:
iSelection - Sets current radiogroup selection to the one specified by value (by index).

Reimplemented in CGUITabControl.

Definition at line 100 of file GUIRadioGroup.cpp.

References CDoubleList< CGUIElement * >::begin(), CGUIElement::GetChildCount(), CGUIElement::GetType(), m_iCurBtnSel, CDoubleList< CGUIElement * >::next(), and CDoubleList< CGUIElement * >::set_ptr().

Referenced by LoadXML(), ProcessMessage(), and PropertyChanging().


Member Data Documentation

int CGUIRadioGroup::m_iCurBtnSel [protected]
 

Current selection index - '-1' if none is selected Definition at line 2060 of file GUI.h.

Referenced by GetCurSel(), GetProperties(), Initialize(), PropertyChanging(), SaveXML(), and SetCurSel().


The documentation for this class was generated from the following files:
Generated on Sun Jul 17 21:34:29 2005 for OpenGL GUI by doxygen 1.3.8