The Battle for Wesnoth  1.13.4+dev
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Modules Pages
Public Member Functions | Private Attributes | List of all members
gui2::iterator::tgrid Class Reference

A walker for a gui2::tgrid. More...

#include <walker_grid.hpp>

Inheritance diagram for gui2::iterator::tgrid:
Inheritance graph

Public Member Functions

 tgrid (gui2::tgrid &grid)
 Constructor. More...
 
virtual tstate next (const tlevel level)
 Inherited from gui2::iterator::twalker_. More...
 
virtual bool at_end (const tlevel level) const
 Inherited from gui2::iterator::twalker_. More...
 
virtual gui2::twidgetget (const tlevel level)
 Inherited from gui2::iterator::twalker_. More...
 
- Public Member Functions inherited from gui2::iterator::twalker_
virtual ~twalker_ ()
 

Private Attributes

gui2::tgridgrid_
 The grid which the walker is attached to. More...
 
gui2::twidgetwidget_
 The grid which the walker is attached to. More...
 
gui2::tgrid::iterator itor_
 The iterator to the children of grid_. More...
 

Additional Inherited Members

- Public Types inherited from gui2::iterator::twalker_
enum  tlevel { widget, grid, child }
 The level to walk at. More...
 
enum  tstate { valid, invalid, fail }
 The state of the walker. More...
 

Detailed Description

A walker for a gui2::tgrid.

Definition at line 29 of file walker_grid.hpp.

Constructor & Destructor Documentation

gui2::iterator::tgrid::tgrid ( gui2::tgrid grid)
explicit

Constructor.

Parameters
gridThe grid which the walker is attached to.

Definition at line 27 of file walker_grid.cpp.

Member Function Documentation

bool gui2::iterator::tgrid::at_end ( const tlevel  level) const
virtual
gui2::twidget * gui2::iterator::tgrid::get ( const tlevel  level)
virtual
twalker_::tstate gui2::iterator::tgrid::next ( const tlevel  level)
virtual

Member Data Documentation

gui2::tgrid& gui2::iterator::tgrid::grid_
private

The grid which the walker is attached to.

Definition at line 50 of file walker_grid.hpp.

Referenced by at_end(), get(), and next().

gui2::tgrid::iterator gui2::iterator::tgrid::itor_
private

The iterator to the children of grid_.

This variable is used to track where the gui2::iterator::twalker_::child level visiting is.

Definition at line 66 of file walker_grid.hpp.

Referenced by at_end(), get(), and next().

gui2::twidget* gui2::iterator::tgrid::widget_
private

The grid which the walker is attached to.

This variable is used to track whether the gui2::iterator::twalker_::widget level has been visited.

Definition at line 58 of file walker_grid.hpp.

Referenced by at_end(), get(), and next().


The documentation for this class was generated from the following files: