Class InputEventMouseButton
Represents a mouse button being pressed or released.
- Inheritance
-
InputEventMouseButton
Remarks
Stores information about mouse click events. See Node._input.
Note: On Wear OS devices, rotary input is mapped to @GlobalScope.MOUSE_BUTTON_WHEEL_UP and @GlobalScope.MOUSE_BUTTON_WHEEL_DOWN. This can be changed to @GlobalScope.MOUSE_BUTTON_WHEEL_LEFT and @GlobalScope.MOUSE_BUTTON_WHEEL_RIGHT with the input_devices/pointing/android/rotary_input_scroll_axis setting.
See Also
Properties
button_index
The mouse button identifier, one of the MouseButton button or button wheel constants.
var button_index : int = 0
Property Value
Remarks
canceled
If true
, the mouse button event has been canceled.
var canceled : bool = false
Property Value
Remarks
double_click
If true
, the mouse button's state is a double-click.
var double_click : bool = false
Property Value
Remarks
factor
The amount (or delta) of the event. When used for high-precision scroll events, this indicates the scroll amount (vertical or horizontal). This is only supported on some platforms; the reported sensitivity varies depending on the platform. May be 0
if not supported.
var factor : float = 1.0
Property Value
Remarks
pressed
If true
, the mouse button's state is pressed. If false
, the mouse button's state is released.
var pressed : bool = false