Class Index

View All Classes

Class vs.core.Event

An vs.core.Event object, or simply an event, contains information about an input action such as a button click or a key down. The Event object contains pertinent information about each event, such as where the cursor was located or which character was typed.
When an event is catch by an application component, the callback receives as parameters an instance (or sub instance) of this class.

It specifies the source of the event (which object has generated the event), the type of the event and an event data.

Class Summary
Constructor Attributes Constructor Name and Description
 
vs.core.Event(src, type, data)
Field Summary
Field Attributes Field Name and Description
 
The optional data associate to the event.
 
src
The component which produce the event
 
[Deprecated] The component which produce the event.
 
The event spec.
Class Detail
vs.core.Event(src, type, data)

Author: David Thevenin.
Parameters:
{vs.core.EventSource} src
the source of the event [mandatory]
{string} type
the event type [mandatory]
{Object} data
complemetary event data [optional]
Field Detail
data
The optional data associate to the event.

src
The component which produce the event

srcTarget
[Deprecated] The component which produce the event.
In case of DOM event, the Event is mapped to the DOM event. Then the developer has access to srcTarget (and many other data).

type
The event spec. For instance 'click' for a mouse click event.