MityDSP Documentation Index
Public Member Functions | Protected Attributes
MityDSP::tcGuiListItem Class Reference

#include <ggui/gui_listbox.h>

List of all members.

Public Member Functions

 tcGuiListItem ()
 Default constructor - an empty list item.
 tcGuiListItem (const char *apString, tcGuiImage *apImage=NULL)
 Construct an item with a label.
 tcGuiListItem (const tcGuiListItem &arOther)
 Copy constuctor.
tcGuiListItemoperator= (const tcGuiListItem &arOther)
 Assignment operator.
 ~tcGuiListItem ()
 Destructor.
void SetText (const char *apString)
 Set the item text.
const char * Text () const
 Get the item text. Get the text of the item.
void SetSelected (bool abSelected)
 Set the selected state of the item.
bool IsSelected () const
 Get the item text. Get the selected state of the item.

Protected Attributes

char * m_string
 Item text.
bool m_selected
 Is the item selected.
tcGuiImagem_image
 Image for the item (not used)

Detailed Description

The tcGuiListItem class holds information about items in a tcGuiListBox.

See also:
tcGuiListbox Page

Constructor & Destructor Documentation

tcGuiListItem::tcGuiListItem ( )

Default constructor - an empty list item.

Default constructor for a tcGuiListItem

MityDSP::tcGuiListItem::tcGuiListItem ( const char *  apString,
tcGuiImage apImage = NULL 
)

Construct an item with a label.

tcGuiListItem::tcGuiListItem ( const tcGuiListItem arOther)

Copy constuctor.

Copy constructor - uses assignment operator

See also:
tcGuiListItem::operator = (const tcGuiListItem & arOther)
Parameters:
[in]arOtherObject to copy.
tcGuiListItem::~tcGuiListItem ( )

Destructor.

destructor - clean up string data, leave image alone as it belongs to the bench.


Member Function Documentation

tcGuiListItem & tcGuiListItem::operator= ( const tcGuiListItem arOther)

Assignment operator.

Assignment operator for list items. Copies the string data, keeps the image as a pointer to the source image as images belong to the bench.

Parameters:
[in]arOtherRHS of assignment
Returns:
reference to the object (LHS)
void tcGuiListItem::SetText ( const char *  apString)

Set the item text.

Set the text of the list item to the string passed in. memory is allocated and string copied.

Parameters:
[in]apStringtext to set.
const char* MityDSP::tcGuiListItem::Text ( ) const
inline

Get the item text. Get the text of the item.

Returns:
pointer to internal string data.
void tcGuiListItem::SetSelected ( bool  abSelected)

Set the selected state of the item.

Set the selected state of the list item.

Parameters:
[in]abSelectedtrue to select.
bool MityDSP::tcGuiListItem::IsSelected ( ) const
inline

Get the item text. Get the selected state of the item.

Returns:
true if item is selected.

Member Data Documentation

char* MityDSP::tcGuiListItem::m_string
protected

Item text.

bool MityDSP::tcGuiListItem::m_selected
protected

Is the item selected.

tcGuiImage* MityDSP::tcGuiListItem::m_image
protected

Image for the item (not used)


  
Generated on Mon Apr 22 2013 11:33:50 for MityDSP Skinnable Graphics User Interface (GGUI) by  Doxygen Version 1.8.1.1
Copyright © 2009, Critical Link LLC, All rights reserved.