gcn::ListModel Class Reference

#include <listmodel.hpp>

List of all members.


Detailed Description

Represents a list.

It is used in certain Widgets, like the ListBox, to handle a list with string elements. If you want to use Widgets like ListBox, you should inherit from this calss and implement it's functions.

Definition at line 72 of file listmodel.hpp.

Public Member Functions

virtual ~ListModel ()
 Destructor.
virtual int getNumberOfElements ()=0
 Gets the number of elements in the ListModel.
virtual std::string getElementAt (int i)=0
 Gets an element at a certain index in the list.


Member Function Documentation

virtual std::string gcn::ListModel::getElementAt ( int  i  )  [pure virtual]

Gets an element at a certain index in the list.

Parameters:
i an index in the list.
Returns:
an element as a string.

Referenced by gcn::ListBox::draw(), and gcn::DropDown::draw().

virtual int gcn::ListModel::getNumberOfElements (  )  [pure virtual]

Gets the number of elements in the ListModel.

Returns:
the number of elements in the ListModel

Referenced by gcn::ListBox::adjustSize(), gcn::ListBox::draw(), and gcn::ListBox::setSelected().


The documentation for this class was generated from the following file:
Generated on Sat Jul 29 19:38:48 2006 for Guichan by  doxygen 1.4.7