#include <mouseinput.hpp>
Generally you won't have to bother using this class.
Definition at line 69 of file mouseinput.hpp.
Public Types | |
EMPTY = 0 | |
LEFT | |
RIGHT | |
MIDDLE | |
WHEEL_UP | |
WHEEL_DOWN | |
PRESS | |
RELEASE | |
MOTION | |
enum | { EMPTY = 0, LEFT, RIGHT, MIDDLE, WHEEL_UP, WHEEL_DOWN, PRESS, RELEASE, MOTION } |
Enum with mouse input values. | |
Public Member Functions | |
MouseInput () | |
Constructor. | |
MouseInput (int button, int type, int mousex, int mousey, int timeStamp) | |
Constructor. | |
void | setType (int type) |
Sets the input type. | |
int | getType () const |
Gets the input type. | |
void | setButton (int button) |
Sets the button pressed. | |
int | getButton () const |
Gets the button pressed. | |
void | setTimeStamp (int timeStamp) |
Sets the timestamp for the input. | |
int | getTimeStamp () const |
Gets the time stamp of the input. | |
Public Attributes | |
int | x |
int | y |
Protected Attributes | |
int | mType |
int | mButton |
int | mTimeStamp |
gcn::MouseInput::MouseInput | ( | int | button, | |
int | type, | |||
int | mousex, | |||
int | mousey, | |||
int | timeStamp | |||
) |
Constructor.
button | the button pressed. | |
type | the type of input. | |
mousex | the mouse x coordinate. | |
mousey | the mouse y coordinate. | |
timeStamp | the mouse inputs time stamp. |
Definition at line 65 of file mouseinput.cpp.
References mButton, mTimeStamp, mType, x, and y.
int gcn::MouseInput::getButton | ( | ) | const |
Gets the button pressed.
Definition at line 89 of file mouseinput.cpp.
References mButton.
Referenced by gcn::Widget::_mouseInputMessage().
int gcn::MouseInput::getTimeStamp | ( | ) | const |
Gets the time stamp of the input.
Definition at line 94 of file mouseinput.cpp.
References mTimeStamp.
Referenced by gcn::Widget::_mouseInputMessage().
int gcn::MouseInput::getType | ( | ) | const |
Gets the input type.
Definition at line 79 of file mouseinput.cpp.
References mType.
Referenced by gcn::Widget::_mouseInputMessage().
void gcn::MouseInput::setButton | ( | int | button | ) |
Sets the button pressed.
button | the button pressed. |
Definition at line 84 of file mouseinput.cpp.
References mButton.
Referenced by gcn::SDLInput::pushInput(), gcn::GLUTInput::pushMotionInput(), and gcn::GLUTInput::pushMouseInput().
void gcn::MouseInput::setTimeStamp | ( | int | timeStamp | ) |
Sets the timestamp for the input.
timeStamp | the timestamp of the input. |
Definition at line 99 of file mouseinput.cpp.
References mTimeStamp.
Referenced by gcn::SDLInput::pushInput().
void gcn::MouseInput::setType | ( | int | type | ) |
Sets the input type.
type | the type of input. |
Definition at line 74 of file mouseinput.cpp.
References mType.
Referenced by gcn::SDLInput::pushInput(), gcn::GLUTInput::pushMotionInput(), and gcn::GLUTInput::pushMouseInput().