stdweb icon indicating copy to clipboard operation
stdweb copied to clipboard

How to get mouse position from a MouseDownEvent?

Open Boscop opened this issue 7 years ago • 1 comments

How to get mouse position from a MouseDownEvent and similar mouse events (mousemove, etc)?

Boscop avatar Jul 30 '18 00:07 Boscop

You'd use client_x and client_y. They're on the IMouseEvent trait, so that way they work on all of the mouse-related events.

Pauan avatar Jul 30 '18 01:07 Pauan