The mouse event.
More...
#include <EventMouse.h>
Inherits Event.
|
unsigned int | _ID |
| object id, ScriptSupport need public _ID
|
|
int | _luaID |
| Lua reference id.
|
|
◆ MouseEventType
◆ EventMouse()
Constructor.
- Parameters
-
mouseEventCode | A given mouse event type. @js ctor |
◆ setScrollData()
void setScrollData |
( |
float | scrollX, |
|
|
float | scrollY ) |
|
inline |
Set mouse scroll data.
- Parameters
-
scrollX | The scroll data of x axis. |
scrollY | The scroll data of y axis. |
◆ getScrollX()
float getScrollX |
( |
| ) |
const |
|
inline |
Get mouse scroll data of x axis.
- Returns
- The scroll data of x axis.
◆ getScrollY()
float getScrollY |
( |
| ) |
const |
|
inline |
Get mouse scroll data of y axis.
- Returns
- The scroll data of y axis.
◆ setMouseInfo()
void setMouseInfo |
( |
float | x, |
|
|
float | y, |
|
|
MouseButton | button ) |
|
inline |
Set the cursor position.
- Parameters
-
x | The x coordinate of cursor position. |
y | The y coordinate of cursor position. @js setLocation |
◆ setMouseButton()
void setMouseButton |
( |
MouseButton | button | ) |
|
|
inline |
Set mouse button.
- Parameters
-
button | a given mouse button. @js setButton |
◆ getMouseButton()
MouseButton getMouseButton |
( |
| ) |
const |
|
inline |
Get mouse button.
- Returns
- The mouse button. @js getButton
◆ AX_DEPRECATED() [1/2]
AX_DEPRECATED |
( |
2. | 2 | ) |
const |
|
inline |
Get the cursor position of x axis.
- Returns
- The x coordinate of cursor position. @js getLocationX
◆ AX_DEPRECATED() [2/2]
AX_DEPRECATED |
( |
2. | 2 | ) |
const |
|
inline |
Get the cursor position of y axis.
- Returns
- The y coordinate of cursor position. @js getLocationY
◆ getLocation()
Vec2 getLocation |
( |
| ) |
const |
Returns the current touch location in OpenGL coordinates.
- Returns
- The current touch location in OpenGL coordinates.
◆ getPreviousLocation()
Vec2 getPreviousLocation |
( |
| ) |
const |
Returns the previous touch location in OpenGL coordinates.
- Returns
- The previous touch location in OpenGL coordinates. @js NA
◆ getStartLocation()
Vec2 getStartLocation |
( |
| ) |
const |
Returns the start touch location in OpenGL coordinates.
- Returns
- The start touch location in OpenGL coordinates. @js NA
◆ getDelta()
Returns the delta of 2 current touches locations in screen coordinates.
- Returns
- The delta of 2 current touches locations in screen coordinates.
◆ getLocationInView()
Vec2 getLocationInView |
( |
| ) |
const |
Returns the current touch location in screen coordinates.
- Returns
- The current touch location in screen coordinates.
◆ getPreviousLocationInView()
Vec2 getPreviousLocationInView |
( |
| ) |
const |
Returns the previous touch location in screen coordinates.
- Returns
- The previous touch location in screen coordinates. @js NA
◆ getStartLocationInView()
Vec2 getStartLocationInView |
( |
| ) |
const |
Returns the start touch location in screen coordinates.
- Returns
- The start touch location in screen coordinates. @js NA
The documentation for this class was generated from the following file: