OpenWalnut  1.4.0
Public Member Functions | Private Attributes
WOSGButtonLabel Class Reference

implements mouse interaction for a osgWidget label More...

#include <WOSGButtonLabel.h>

+ Inheritance diagram for WOSGButtonLabel:

List of all members.

Public Member Functions

 WOSGButtonLabel (bool pushable)
 constructor
 ~WOSGButtonLabel ()
 destructor
bool mousePush (double, double, osgWidget::WindowManager *)
 function handles mouse click on label, the function was copied from an osg example, as everything in the osg it wasn't documented, so it's not entirely sure what the params are for and what they do
bool clicked ()
 getter for clicked flag, resets the flag to false
bool pushed ()
 getter for pushed flag
void setPushed (bool pushed)
 setter

Private Attributes

bool m_clicked
 if true the label has been clicked since it was last checked for
bool m_pushable
 button is pushable or not
bool m_pushed
 true if button is pushable and was clicked

Detailed Description

implements mouse interaction for a osgWidget label

Definition at line 35 of file WOSGButtonLabel.h.


Constructor & Destructor Documentation

WOSGButtonLabel::WOSGButtonLabel ( bool  pushable) [explicit]

constructor

Parameters:
pushabledenotes if the button is pushable, i.e. keeps a pushed state or not

Definition at line 27 of file WOSGButtonLabel.cpp.

destructor

Definition at line 41 of file WOSGButtonLabel.cpp.


Member Function Documentation

bool WOSGButtonLabel::clicked ( ) [inline]

getter for clicked flag, resets the flag to false

Returns:
true if the label has been clicked

Definition at line 86 of file WOSGButtonLabel.h.

References m_clicked.

Referenced by WOSGButton::clicked().

bool WOSGButtonLabel::mousePush ( double  ,
double  ,
osgWidget::WindowManager *   
)

function handles mouse click on label, the function was copied from an osg example, as everything in the osg it wasn't documented, so it's not entirely sure what the params are for and what they do

Returns:
bool

Definition at line 45 of file WOSGButtonLabel.cpp.

References m_clicked, m_pushable, and m_pushed.

bool WOSGButtonLabel::pushed ( ) [inline]

getter for pushed flag

Returns:
true if the button is pushed

Definition at line 93 of file WOSGButtonLabel.h.

References m_pushed.

Referenced by WOSGButton::pushed(), and setPushed().

void WOSGButtonLabel::setPushed ( bool  pushed) [inline]

setter

Parameters:
pushedif true the button is pushed

Definition at line 98 of file WOSGButtonLabel.h.

References m_pushed, and pushed().

Referenced by WOSGButton::setPushed().


Member Data Documentation

if true the label has been clicked since it was last checked for

Definition at line 79 of file WOSGButtonLabel.h.

Referenced by clicked(), and mousePush().

button is pushable or not

Definition at line 81 of file WOSGButtonLabel.h.

Referenced by mousePush().

bool WOSGButtonLabel::m_pushed [private]

true if button is pushable and was clicked

Definition at line 83 of file WOSGButtonLabel.h.

Referenced by mousePush(), pushed(), and setPushed().


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