The Battle for Wesnoth  1.19.7+dev
Public Member Functions | Private Attributes | List of all members
gui2::iteration::walker::widget Class Reference

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

#include <walker_widget.hpp>

Inheritance diagram for gui2::iteration::walker::widget:

Public Member Functions

 widget (gui2::widget &widget)
 Constructor. More...
 
virtual state_t next (const level level)
 Inherited from gui2::iteration::walker_base. More...
 
virtual bool at_end (const level level) const
 Inherited from gui2::iteration::walker_base. More...
 
virtual gui2::widgetget (const level level)
 Inherited from gui2::iteration::walker_base. More...
 
- Public Member Functions inherited from gui2::iteration::walker_base
virtual ~walker_base ()
 

Private Attributes

gui2::widgetwidget_
 The styled_widget which the walker is attached to. More...
 

Additional Inherited Members

- Public Types inherited from gui2::iteration::walker_base
enum  level { self , internal , child }
 The level to walk at. More...
 
enum  state_t { valid , invalid , fail }
 The state of the walker. More...
 

Detailed Description

A walker for a gui2::styled_widget.

Definition at line 24 of file walker_widget.hpp.

Constructor & Destructor Documentation

◆ widget()

gui2::iteration::walker::widget::widget ( gui2::widget widget)
explicit

Constructor.

Parameters
widgetThe styled_widget which the walker is attached to.

Definition at line 27 of file walker_widget.cpp.

Member Function Documentation

◆ at_end()

bool gui2::iteration::walker::widget::at_end ( const level  level) const
virtual

Inherited from gui2::iteration::walker_base.

Implements gui2::iteration::walker_base.

Definition at line 53 of file walker_widget.cpp.

References gui2::iteration::walker_base::child, and widget_.

Referenced by next().

◆ get()

gui2::widget * gui2::iteration::walker::widget::get ( const level  level)
virtual

Inherited from gui2::iteration::walker_base.

Implements gui2::iteration::walker_base.

Definition at line 67 of file walker_widget.cpp.

References gui2::iteration::walker_base::child, and widget_.

◆ next()

walker_base::state_t gui2::iteration::walker::widget::next ( const level  level)
virtual

Member Data Documentation

◆ widget_

gui2::widget* gui2::iteration::walker::widget::widget_
private

The styled_widget which the walker is attached to.

Definition at line 45 of file walker_widget.hpp.

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


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