Home > @modelo.io/api > Mouse

Mouse class

Signature:

export default class Mouse extends Input 

Constructors

ConstructorDescription
(constructor)(viewer)Constructs a new instance of the Mouse class

Properties

PropertyModifiersDescription
button
delta
dx
dy
moved
pressed
x
y

Methods

MethodDescription
addMouseDownListener(cbk)Add a mouse button down callback.
addMouseMoveListener(cbk)Add a mouse move callback.
addMouseUpListener(cbk)Add a mouse button up callback.
addMouseWheelListener(cbk)Add a mouse wheel callback.
destroy()Destroy the mouse object.