PointerEvent extension type

The PointerEvent interface represents the state of a DOM event produced by a pointer such as the geometry of the contact point, the device type that generated the event, the amount of pressure that was applied on the contact surface, etc.

A pointer is a hardware agnostic representation of input devices (such as a mouse, pen or contact point on a touch-enable surface). The pointer can target a specific coordinate (or set of coordinates) on the contact surface such as a screen.

A pointer's hit test is the process a browser uses to determine the target element for a pointer event. Typically, this is determined by considering the pointer's location and also the visual layout of elements in a document on screen media.

on
Implemented types

Constructors

PointerEvent(String type, [PointerEventInit eventInitDict])
factory

Properties

altitudeAngle num
no setter
altKey bool
no setterinherited
azimuthAngle num
no setter
bubbles bool
no setterinherited
button int
no setterinherited
buttons int
no setterinherited
cancelable bool
no setterinherited
cancelBubble bool
getter/setter pairinherited
clientX int
no setterinherited
clientY int
no setterinherited
composed bool
no setterinherited
ctrlKey bool
no setterinherited
currentTarget EventTarget?
no setterinherited
defaultPrevented bool
no setterinherited
detail int
no setterinherited
eventPhase int
no setterinherited
hashCode int
The hash code for this object.
no setterinherited
height num
no setter
isPrimary bool
no setter
isTrusted bool
no setterinherited
layerX int
no setterinherited
layerY int
no setterinherited
metaKey bool
no setterinherited
offsetX num
no setterinherited
offsetY num
no setterinherited
pageX num
no setterinherited
pageY num
no setterinherited
pointerId int
no setter
pointerType String
no setter
pressure num
no setter
relatedTarget EventTarget?
no setterinherited
returnValue bool
getter/setter pairinherited
runtimeType Type
A representation of the runtime type of the object.
no setterinherited
screenX int
no setterinherited
screenY int
no setterinherited
shiftKey bool
no setterinherited
srcElement EventTarget?
no setterinherited
tangentialPressure num
no setter
target EventTarget?
no setterinherited
tiltX int
no setter
tiltY int
no setter
timeStamp DOMHighResTimeStamp
no setterinherited
twist int
no setter
type String
no setterinherited
view Window?
no setterinherited
which int
no setterinherited
width num
no setter
x num
no setterinherited
y num
no setterinherited

Methods

composedPath() JSArray<EventTarget>
The composedPath() method of the Event interface returns the event's path which is an array of the objects on which listeners will be invoked. This does not include nodes in shadow trees if the shadow root was created with its ShadowRoot.mode closed.
inherited
getCoalescedEvents() JSArray<PointerEvent>
The getCoalescedEvents() method of the PointerEvent interface returns a sequence of PointerEvent instances that were coalesced (merged) into a single Element/pointermove_event or Element/pointerrawupdate_event event. Instead of a stream of many Element/pointermove_event events, user agents coalesce multiple updates into a single event. This helps with performance as the user agent has less event handling to perform, but there is a reduction in the granularity and accuracy when tracking, especially with fast and large movements.
getModifierState(String keyArg) bool
The MouseEvent.getModifierState() method returns the current state of the specified modifier key: true if the modifier is active (i.e., the modifier key is pressed or locked), otherwise, false.
inherited
getPredictedEvents() JSArray<PointerEvent>
The getPredictedEvents() method of the PointerEvent interface returns a sequence of PointerEvent instances that are estimated future pointer positions. How the predicted positions are calculated depends on the user agent, but they are based on past points, current velocity, and trajectory.
initEvent(String type, [bool bubbles, bool cancelable]) → void
The Event.initEvent() method is used to initialize the value of an event created using Document.createEvent.
inherited
initMouseEvent(String typeArg, [bool bubblesArg, bool cancelableArg, Window? viewArg, int detailArg, int screenXArg, int screenYArg, int clientXArg, int clientYArg, bool ctrlKeyArg, bool altKeyArg, bool shiftKeyArg, bool metaKeyArg, int buttonArg, EventTarget? relatedTargetArg]) → void
The MouseEvent.initMouseEvent() method initializes the value of a mouse event once it's been created (normally using the Document.createEvent method).
inherited
initUIEvent(String typeArg, [bool bubblesArg, bool cancelableArg, Window? viewArg, int detailArg]) → void
The UIEvent.initUIEvent() method initializes a UI event once it's been created.
inherited
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
preventDefault() → void
The preventDefault() method of the Event interface tells the that if the event does not get explicitly handled, its default action should not be taken as it normally would be.
inherited
stopImmediatePropagation() → void
The stopImmediatePropagation() method of the Event interface prevents other listeners of the same event from being called.
inherited
stopPropagation() → void
The stopPropagation() method of the Event interface prevents further propagation of the current event in the capturing and bubbling phases. It does not, however, prevent any default behaviors from occurring; for instance, clicks on links are still processed. If you want to stop those behaviors, see the Event.preventDefault method. It also does not prevent propagation to other event-handlers of the current element. If you want to stop those, see Event.stopImmediatePropagation.
inherited
toString() String
A string representation of this object.
inherited

Operators

operator ==(Object other) bool
The equality operator.
inherited