GLWSpinBox Class Reference

#include <GLWSpinBox.h>

Inheritance diagram for GLWSpinBox:

GLWidget GLWButtonI MetaClass

List of all members.

Public Member Functions

 GLWSpinBox (float x=0.0f, float y=0.0f, float w=0.0f, int start=0, int minRange=0, int maxRange=0, int step=1)
virtual ~GLWSpinBox ()
virtual void draw ()
virtual void mouseDown (int button, float x, float y, bool &skipRest)
virtual void mouseUp (int button, float x, float y, bool &skipRest)
virtual void mouseDrag (int button, float mx, float my, float x, float y, bool &skipRest)
virtual void keyDown (char *buffer, unsigned int keyState, KeyboardHistory::HistoryElement *history, int hisCount, bool &skipRest)
virtual void buttonDown (unsigned int id)
int getValue ()
 REGISTER_CLASS_HEADER (GLWSpinBox)

Protected Attributes

bool keyDown_
bool dragging_
int step_
int value_
int minRange_
int maxRange_
GLWButton top_
GLWButton bottom_


Detailed Description

Definition at line 26 of file GLWSpinBox.h.


Constructor & Destructor Documentation

GLWSpinBox::GLWSpinBox ( float  x = 0.0f,
float  y = 0.0f,
float  w = 0.0f,
int  start = 0,
int  minRange = 0,
int  maxRange = 0,
int  step = 1 
)

Definition at line 28 of file GLWSpinBox.cpp.

References bottom_, GLWButton::setHandler(), and top_.

GLWSpinBox::~GLWSpinBox (  )  [virtual]

Definition at line 39 of file GLWSpinBox.cpp.


Member Function Documentation

void GLWSpinBox::draw (  )  [virtual]

Reimplemented from GLWidget.

Definition at line 44 of file GLWSpinBox.cpp.

References bottom_, GLFont2d::draw(), GLWButton::draw(), GLWidget::drawShadedRoundBox(), S3D::formatStringBuffer(), GLWFont::getGameFont(), GLWButton::getPressed(), GL_LINE_LOOP, GL_TRIANGLES, glBegin(), glColor3f(), glEnd(), glVertex2d(), GLWidget::h_, GLWFont::instance(), top_, value_, GLWidget::w_, GLWFont::widgetFontColor, GLWidget::x_, and GLWidget::y_.

void GLWSpinBox::mouseDown ( int  button,
float  x,
float  y,
bool &  skipRest 
) [virtual]

Reimplemented from GLWidget.

Definition at line 76 of file GLWSpinBox.cpp.

References bottom_, dragging_, GLWidget::h_, GLWidget::inBox(), GLWButton::mouseDown(), top_, GLWidget::w_, GLWidget::x_, and GLWidget::y_.

void GLWSpinBox::mouseUp ( int  button,
float  x,
float  y,
bool &  skipRest 
) [virtual]

Reimplemented from GLWidget.

Definition at line 92 of file GLWSpinBox.cpp.

References bottom_, dragging_, GLWButton::mouseUp(), and top_.

void GLWSpinBox::mouseDrag ( int  button,
float  mx,
float  my,
float  x,
float  y,
bool &  skipRest 
) [virtual]

Reimplemented from GLWidget.

Definition at line 102 of file GLWSpinBox.cpp.

References bottom_, dragging_, maxRange_, minRange_, GLWButton::mouseDrag(), step_, top_, and value_.

void GLWSpinBox::keyDown ( char *  buffer,
unsigned int  keyState,
KeyboardHistory::HistoryElement history,
int  hisCount,
bool &  skipRest 
) [virtual]

Reimplemented from GLWidget.

Definition at line 119 of file GLWSpinBox.cpp.

References maxRange_, minRange_, KeyboardHistory::HistoryElement::sdlKey, step_, and value_.

void GLWSpinBox::buttonDown ( unsigned int  id  )  [virtual]

Implements GLWButtonI.

Definition at line 142 of file GLWSpinBox.cpp.

References bottom_, GLWidget::getId(), maxRange_, minRange_, step_, top_, and value_.

int GLWSpinBox::getValue (  )  [inline]

Definition at line 43 of file GLWSpinBox.h.

References value_.

GLWSpinBox::REGISTER_CLASS_HEADER ( GLWSpinBox   ) 


Member Data Documentation

bool GLWSpinBox::keyDown_ [protected]

Definition at line 48 of file GLWSpinBox.h.

bool GLWSpinBox::dragging_ [protected]

Definition at line 49 of file GLWSpinBox.h.

Referenced by mouseDown(), mouseDrag(), and mouseUp().

int GLWSpinBox::step_ [protected]

Definition at line 50 of file GLWSpinBox.h.

Referenced by buttonDown(), keyDown(), and mouseDrag().

int GLWSpinBox::value_ [protected]

Definition at line 51 of file GLWSpinBox.h.

Referenced by buttonDown(), draw(), getValue(), keyDown(), and mouseDrag().

int GLWSpinBox::minRange_ [protected]

Definition at line 52 of file GLWSpinBox.h.

Referenced by buttonDown(), keyDown(), and mouseDrag().

int GLWSpinBox::maxRange_ [protected]

Definition at line 52 of file GLWSpinBox.h.

Referenced by buttonDown(), keyDown(), and mouseDrag().

GLWButton GLWSpinBox::top_ [protected]

Definition at line 53 of file GLWSpinBox.h.

Referenced by buttonDown(), draw(), GLWSpinBox(), mouseDown(), mouseDrag(), and mouseUp().

GLWButton GLWSpinBox::bottom_ [protected]

Definition at line 53 of file GLWSpinBox.h.

Referenced by buttonDown(), draw(), GLWSpinBox(), mouseDown(), mouseDrag(), and mouseUp().


The documentation for this class was generated from the following files:
Generated on Mon Feb 16 15:15:02 2009 for Scorched3D by  doxygen 1.5.3