Name

Event — information about an event

Availability

DOM Level 2 Events

Subinterfaces

MutationEvent, UIEvent

Constants

These constants are the legal values of the eventPhase property; they represent the current phase of event propagation for this event:

unsigned short CAPTURING_PHASE = 1

The event is in its capturing phase.

unsigned short AT_TARGET = 2

The event is being handled by its target node.

unsigned short BUBBLING_PHASE = 3

The event is bubbling.

Properties

readonly boolean bubbles

true if the event is of a type that bubbles (unless stopPropagation( ) is called); false otherwise.

readonly boolean cancelable

true if the default action associated with the event can be canceled with preventDefault( ); false otherwise.

readonly EventTarget currentTarget

The Document node that is currently handling this event. During capturing and bubbling, this is different from target. Note that all nodes implement the EventTarget interface, and the currentTarget property may refer to any node; it is not restricted to Element nodes.

readonly unsigned short eventPhase

The current phase of event propagation. The three previous constants define the legal values for this property.

readonly EventTarget target

The target node for this event; i.e., the node that generated the event. Note that this may be any node; it is not restricted to Element nodes.

readonly Date timeStamp

The date and time at which the event occurred (or, technically, at which the Event object was created). Implementations ...

Get JavaScript: The Definitive Guide, Fourth Edition now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.