Raster.getInputState( event )
Returns a mouse object containing the x,y position of the mouse
and the state of the shift, crtl and alt keys.
Parameters
Name |
Type |
|
Description |
event |
object |
|
A DOM event |
Returns
Type |
Description |
object |
An object containing the mouse and key state. The returned
object has the following fields:
x Mouse pointer's X coordinate.
y Mouse pointer's Y coordinate.
ctrl true if the CONTROL key is pressed,
false otherwise.
alt true if the ALT key is pressed,
false otherwise.
shift true if the SHIFT key is pressed,
false otherwise.
button Pressed mouse button:
1=Left, 2=Right, 3=Center. |