MouseEventInit Class

https://w3c.github.io/uievents/#dictdef-mouseeventinit

public class MouseEventInit : EventModifierInit
Inheritance
EventModifierInit MouseEventInit

Constructors

NameDescription
MouseEventInit()

MouseEventInit()

public MouseEventInit()

No documentation is available.

Properties

NameDescription
ButtonGets the button that changed state: 0 for the main button, 1 for the auxiliary button, 2 for the secondary button.
ButtonsGets the bit mask of the buttons that are pressed.
ClientXGets the horizontal coordinate of the pointer relative to the viewport.
ClientYGets the vertical coordinate of the pointer relative to the viewport.
MovementXGets the horizontal distance of the pointer movement since the previous event.
MovementYGets the vertical distance of the pointer movement since the previous event.
RelatedTargetGets the secondary target of the event (for example the element the pointer left), or null.
ScreenXGets the horizontal coordinate of the pointer relative to the screen.
ScreenYGets the vertical coordinate of the pointer relative to the screen.

Gets the button that changed state: 0 for the main button, 1 for the auxiliary button, 2 for the secondary button.

public short Button { get; init; }

Gets the bit mask of the buttons that are pressed.

public ushort Buttons { get; init; }

Gets the horizontal coordinate of the pointer relative to the viewport.

public double ClientX { get; init; }

Gets the vertical coordinate of the pointer relative to the viewport.

public double ClientY { get; init; }

MovementX

UIEvents.cs

Gets the horizontal distance of the pointer movement since the previous event.

public double MovementX { get; init; }

MovementY

UIEvents.cs

Gets the vertical distance of the pointer movement since the previous event.

public double MovementY { get; init; }

RelatedTarget

UIEvents.cs

Gets the secondary target of the event (for example the element the pointer left), or null.

public EventTarget? RelatedTarget { get; init; }

Gets the horizontal coordinate of the pointer relative to the screen.

public double ScreenX { get; init; }

Gets the vertical coordinate of the pointer relative to the screen.

public double ScreenY { get; init; }