TDME2 1.9.121
Public Member Functions | Private Member Functions | Private Attributes | Friends | List of all members
GUIMenuHeaderController Class Referencefinal

GUI menu header controller. More...

#include <tdme/gui/elements/GUIMenuHeaderController.h>

Inheritance diagram for GUIMenuHeaderController:
Inheritance graph
Collaboration diagram for GUIMenuHeaderController:
Collaboration graph

Public Member Functions

bool isDisabled () override
 
void setDisabled (bool disabled) override
 Set disabled. More...
 
void initialize () override
 Initialize controller after element has been created. More...
 
void dispose () override
 Dispose controller. More...
 
void postLayout () override
 Post layout event. More...
 
void handleMouseEvent (GUINode *node, GUIMouseEvent *event) override
 Handle mouse event. More...
 
void handleKeyboardEvent (GUIKeyboardEvent *event) override
 Handle keyboard event. More...
 
void tick () override
 Tick method will be executed once per frame. More...
 
void onFocusGained () override
 On focus gained. More...
 
void onFocusLost () override
 On focus lost. More...
 
bool hasValue () override
 
const MutableStringgetValue () override
 
void setValue (const MutableString &value) override
 Set value. More...
 
void onSubTreeChange () override
 On sub tree change. More...
 
- Public Member Functions inherited from GUINodeController
virtual ~GUINodeController ()
 Destructor. More...
 
virtual GUINodegetNode ()
 
virtual void initialize ()=0
 Initialize controller after element has been created. More...
 
virtual void dispose ()=0
 Dispose controller. More...
 
virtual void postLayout ()=0
 Post layout event. More...
 
virtual void handleMouseEvent (GUINode *node, GUIMouseEvent *event)=0
 Handle mouse event. More...
 
virtual void handleKeyboardEvent (GUIKeyboardEvent *event)=0
 Handle keyboard event. More...
 
virtual void tick ()=0
 Tick method will be executed once per frame. More...
 
virtual void onFocusGained ()=0
 On focus gained. More...
 
virtual void onFocusLost ()=0
 On focus lost. More...
 
virtual bool hasValue ()=0
 
virtual const MutableStringgetValue ()=0
 
virtual void setValue (const MutableString &value)=0
 Set value. More...
 
virtual bool isDisabled ()=0
 
virtual void setDisabled (bool disabled)=0
 Set disabled. More...
 
virtual void onSubTreeChange ()=0
 On sub tree change. More...
 

Private Member Functions

 GUIMenuHeaderController (GUINode *node)
 Private constructor. More...
 
bool hasFocus ()
 
void determineMenuHeaderItemControllers ()
 Determine menu header item controllers. More...
 
bool isOpen ()
 
void unselect ()
 Unselect. More...
 
void selectNext ()
 Select next node. More...
 
void selectPrevious ()
 Select previous. More...
 
void select (int idx)
 Select by index. More...
 
void select (GUIElementNode *elementNode)
 Select element node. More...
 

Private Attributes

vector< GUIMenuHeaderItemController * > menuHeaderItemControllers
 
bool focus
 
MutableString value
 
int menuHeaderItemControllerIdx { -1 }
 

Friends

class GUIMenuHeader
 
class GUIMenuHeaderItemController
 

Additional Inherited Members

- Protected Member Functions inherited from GUINodeController
 GUINodeController (GUINode *node)
 Private constructor. More...
 
- Protected Attributes inherited from GUINodeController
GUINodenode { nullptr }
 

Detailed Description

GUI menu header controller.

Author
Andreas Drewke
Version
$Id$

Definition at line 26 of file GUIMenuHeaderController.h.

Constructor & Destructor Documentation

◆ GUIMenuHeaderController()

GUIMenuHeaderController ( GUINode node)
private

Private constructor.

Parameters
nodenode

Definition at line 29 of file GUIMenuHeaderController.cpp.

Member Function Documentation

◆ determineMenuHeaderItemControllers()

void determineMenuHeaderItemControllers ( )
private

Determine menu header item controllers.

Definition at line 61 of file GUIMenuHeaderController.cpp.

◆ dispose()

void dispose ( )
overridevirtual

Dispose controller.

Implements GUINodeController.

Definition at line 48 of file GUIMenuHeaderController.cpp.

◆ getValue()

const MutableString & getValue ( )
overridevirtual
Returns
value

Implements GUINodeController.

Definition at line 249 of file GUIMenuHeaderController.cpp.

◆ handleKeyboardEvent()

void handleKeyboardEvent ( GUIKeyboardEvent event)
overridevirtual

Handle keyboard event.

Parameters
eventevent

Implements GUINodeController.

Definition at line 167 of file GUIMenuHeaderController.cpp.

◆ handleMouseEvent()

void handleMouseEvent ( GUINode node,
GUIMouseEvent event 
)
overridevirtual

Handle mouse event.

Parameters
nodenode
eventevent

Implements GUINodeController.

Definition at line 157 of file GUIMenuHeaderController.cpp.

◆ hasFocus()

bool hasFocus ( )
private
Returns
has focus

Definition at line 56 of file GUIMenuHeaderController.cpp.

◆ hasValue()

bool hasValue ( )
overridevirtual
Returns
has value

Implements GUINodeController.

Definition at line 244 of file GUIMenuHeaderController.cpp.

◆ initialize()

void initialize ( )
overridevirtual

Initialize controller after element has been created.

Implements GUINodeController.

Definition at line 44 of file GUIMenuHeaderController.cpp.

◆ isDisabled()

bool isDisabled ( )
overridevirtual
Returns
is disabled

Implements GUINodeController.

Definition at line 35 of file GUIMenuHeaderController.cpp.

◆ isOpen()

bool isOpen ( )
private
Returns
if menu is open

Definition at line 78 of file GUIMenuHeaderController.cpp.

◆ onFocusGained()

void onFocusGained ( )
overridevirtual

On focus gained.

Implements GUINodeController.

Definition at line 234 of file GUIMenuHeaderController.cpp.

◆ onFocusLost()

void onFocusLost ( )
overridevirtual

On focus lost.

Implements GUINodeController.

Definition at line 239 of file GUIMenuHeaderController.cpp.

◆ onSubTreeChange()

void onSubTreeChange ( )
overridevirtual

On sub tree change.

Implements GUINodeController.

Definition at line 258 of file GUIMenuHeaderController.cpp.

◆ postLayout()

void postLayout ( )
overridevirtual

Post layout event.

Implements GUINodeController.

Definition at line 52 of file GUIMenuHeaderController.cpp.

◆ select() [1/2]

void select ( GUIElementNode elementNode)
private

Select element node.

Parameters
elementNodeelement node

Definition at line 145 of file GUIMenuHeaderController.cpp.

◆ select() [2/2]

void select ( int  idx)
private

Select by index.

Parameters
idxindex

Definition at line 138 of file GUIMenuHeaderController.cpp.

◆ selectNext()

void selectNext ( )
private

Select next node.

Definition at line 91 of file GUIMenuHeaderController.cpp.

◆ selectPrevious()

void selectPrevious ( )
private

Select previous.

Definition at line 114 of file GUIMenuHeaderController.cpp.

◆ setDisabled()

void setDisabled ( bool  disabled)
overridevirtual

Set disabled.

Parameters
disableddisabled

Implements GUINodeController.

Definition at line 40 of file GUIMenuHeaderController.cpp.

◆ setValue()

void setValue ( const MutableString value)
overridevirtual

Set value.

Parameters
valuevalue

Implements GUINodeController.

Definition at line 254 of file GUIMenuHeaderController.cpp.

◆ tick()

void tick ( )
overridevirtual

Tick method will be executed once per frame.

Implements GUINodeController.

Definition at line 230 of file GUIMenuHeaderController.cpp.

◆ unselect()

void unselect ( )
private

Unselect.

Definition at line 83 of file GUIMenuHeaderController.cpp.

Friends And Related Function Documentation

◆ GUIMenuHeader

friend class GUIMenuHeader
friend

Definition at line 29 of file GUIMenuHeaderController.h.

◆ GUIMenuHeaderItemController

friend class GUIMenuHeaderItemController
friend

Definition at line 30 of file GUIMenuHeaderController.h.

Member Data Documentation

◆ focus

bool focus
private

Definition at line 34 of file GUIMenuHeaderController.h.

◆ menuHeaderItemControllerIdx

int menuHeaderItemControllerIdx { -1 }
private

Definition at line 36 of file GUIMenuHeaderController.h.

◆ menuHeaderItemControllers

vector<GUIMenuHeaderItemController*> menuHeaderItemControllers
private

Definition at line 33 of file GUIMenuHeaderController.h.

◆ value

MutableString value
private

Definition at line 35 of file GUIMenuHeaderController.h.


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