The walker abstract base class. More...
#include <walker.hpp>
Public Types | |
enum | tlevel { widget, grid, child } |
The level to walk at. More... | |
enum | tstate { valid, invalid, fail } |
The state of the walker. More... | |
Public Member Functions | |
virtual | ~twalker_ () |
virtual tstate | next (const tlevel level)=0 |
Make the next widget the current one. More... | |
virtual bool | at_end (const tlevel level) const =0 |
Returns whether the current widget is valid. More... | |
virtual gui2::twidget * | get (const tlevel level)=0 |
Returns a pointer to the current widget. More... | |
The walker abstract base class.
Definition at line 27 of file walker.hpp.
The level to walk at.
Enumerator | |
---|---|
widget |
Visit the widget itself. Visit its nested grid. |
grid |
Visit the children of its nested grid. |
child |
Definition at line 35 of file walker.hpp.
The state of the walker.
The enum is used to return the state of next.
Definition at line 51 of file walker.hpp.
|
inlinevirtual |
Definition at line 30 of file walker.hpp.
|
pure virtual |
Returns whether the current widget is valid.
level | Determines on which level the test should be executed. |
Implemented in gui2::iterator::walker::twidget, and gui2::iterator::tgrid.
Referenced by gui2::iterator::policy::visit::tvisit< level >::at_end().
|
pure virtual |
Returns a pointer to the current widget.
level | Determines from which level should the current widget be returned. |
Implemented in gui2::iterator::walker::twidget, and gui2::iterator::tgrid.
Make the next widget the current one.
level | Determines on which level the next one should be selected. |
Implemented in gui2::iterator::walker::twidget, and gui2::iterator::tgrid.
Referenced by gui2::iterator::policy::visit::tvisit< level >::next().