Event
Module: JavaScript DOM API
#include <Event.idl>
Inherited by AnimationEvent, CustomEvent, ErrorEvent, PopStateEvent, ProgressEvent, PromiseRejectionEvent, TransitionEvent, UIEvent
Public Functions
| Name | |
|---|---|
| Event | Event(DOMInternedString type, optional EventInit initEvent) |
| void | stopPropagation() |
| void | preventDefault() |
| void | initEvent(optional DOMInternedString eventTypeArg, optional boolean canBubbleArg, optional boolean cancelableArg) |
| void | stopImmediatePropagation() |
Public Attributes
| Name | |
|---|---|
| const unsigned short | NONE |
| const unsigned short | CAPTURING_PHASE |
| const unsigned short | AT_TARGET |
| const unsigned short | BUBBLING_PHASE |
| readonly attribute DOMString | type |
| readonly attribute EventTarget | target |
| readonly attribute EventTarget | currentTarget |
| readonly attribute unsigned short | eventPhase |
| readonly attribute boolean | bubbles |
| readonly attribute boolean | cancelable |
| readonly attribute boolean | defaultPrevented |
| readonly attribute boolean | composed |
Public Functions Documentation
function Event
Event Event(
DOMInternedString type,
optional EventInit initEvent
)
function stopPropagation
void stopPropagation()
function preventDefault
void preventDefault()
function initEvent
void initEvent(
optional DOMInternedString eventTypeArg,
optional boolean canBubbleArg,
optional boolean cancelableArg
)
function stopImmediatePropagation
void stopImmediatePropagation()
Public Attributes Documentation
variable NONE
const unsigned short NONE = 0;
variable CAPTURING_PHASE
const unsigned short CAPTURING_PHASE = 1;
variable AT_TARGET
const unsigned short AT_TARGET = 2;
variable BUBBLING_PHASE
const unsigned short BUBBLING_PHASE = 3;
variable type
readonly attribute DOMString type;
variable target
readonly attribute EventTarget target;
variable currentTarget
readonly attribute EventTarget currentTarget;
variable eventPhase
readonly attribute unsigned short eventPhase;
variable bubbles
readonly attribute boolean bubbles;
variable cancelable
readonly attribute boolean cancelable;
variable defaultPrevented
readonly attribute boolean defaultPrevented;
variable composed
readonly attribute boolean composed;