Properties
altKey
altKey: boolean = false
Optional buttons
buttons: undefined | number = 0
canvasPosition
canvasPosition: Vector2 = new Vector2()
ctrlKey
ctrlKey: boolean = false
domElement
domElement: HTMLCanvasElement
doubleClickPending
doubleClickPending: boolean
doubleClickSpeed
doubleClickSpeed: number
down
down: Vector2 = new Vector2()
handleScroll
handleScroll: boolean
hoverTimeout
hoverTimeout: number
hovering
hovering: boolean = true
lastClicked
lastClicked: number
lastMoved
lastMoved: number = Infinity
lastTouchDistance
lastTouchDistance: number
metaKey
metaKey: boolean = false
moving
moving: boolean = false
overElement
overElement: boolean
position
position: Vector2 = new Vector2()
Optional pressed
pressed: undefined | false | true = false
prevClickCP
prevClickCP: Vector2 = new Vector2()
prevPosition
prevPosition: Vector2 = new Vector2()
scrolled
scrolled: boolean = false
shiftKey
shiftKey: boolean = false
Optional which
which: undefined | number = 0
Mouse observer
// listen to mouse moving (and touch-moving) events mouseObserver.moved.moved.add( function( deltaX, deltaY ){ ... } );
// listen to scrolling (and pinching) events mouseObserver.signals.scrolled.add( function( delta ){ ... } );
// listen to dragging (and touch-dragging) events mouseObserver.signals.dragged.add( function( deltaX, deltaY ){ ... } );
// listen to clicking (and tapping) events mouseObserver.signals.clicked.add( function(){ ... } );
// listen to double clicking (and double tapping) events mouseObserver.signals.doubleClicked.add( function(){ ... } );
// listen to hovering events mouseObserver.signals.hovered.add( function(){ ... } );