DotNetBrowser  1.14
Public Member Functions | List of all members
DotNetBrowser.DOM.Events.DOMEventTarget Interface Reference

This interface is implemented by all DOMElement that supports DOM event model. More...

Inherited by DotNetBrowser.DOM.DOMNode.

Public Member Functions

void AddEventListener (DOMEventType eventType, DOMEventHandler handler, bool useCapture)
 This method allows the registration of event listeners on the event target. If an DOMEventHandler is added to an DOMEventTarget while it is processing an event, it will not be triggered by the current actions but may be triggered during a later stage of event flow, such as the bubbling phase.
If multiple identical DOMEventHandlers are registered on the same DOMEventTarget with the same parameters the duplicate instances are discarded. They do not cause the DOMEventHandler to be called twice and since they are discarded they do not need to be removed with the RemoveEventListener method. More...
 
void AddEventListener (DOMEvent domEvent, DOMEventHandler handler, bool useCapture)
 This method allows the registration of event listeners on the event target. If an DOMEventHandler is added to an DOMEventTarget while it is processing an event, it will not be triggered by the current actions but may be triggered during a later stage of event flow, such as the bubbling phase.
If multiple identical DOMEventHandlers are registered on the same DOMEventTarget with the same parameters the duplicate instances are discarded. They do not cause the DOMEventHandler to be called twice and since they are discarded they do not need to be removed with the RemoveEventListener method. More...
 
void RemoveEventListener (DOMEventType eventType, DOMEventHandler handler, bool useCapture)
 This method allows the removal of event listeners from the event target. If an DOMEventHandler is removed from an DOMEventTarget while it is processing an event, it will not be triggered by the current actions. DOMEventHandlers can never be invoked after being removed.
Calling RemoveEventListener with arguments which do not identify any currently registered DOMEventHandler on the DOMEventTarget has no effect. More...
 
void RemoveEventListener (DOMEvent domEvent, DOMEventHandler handler, bool useCapture)
 This method allows the removal of event listeners from the event target. If an DOMEventHandler is removed from an DOMEventTarget while it is processing an event, it will not be triggered by the current actions. DOMEventHandlers can never be invoked after being removed.
Calling RemoveEventListener with arguments which do not identify any currently registered DOMEventHandler on the DOMEventTarget has no effect. More...
 
List< DOMEventHandlerGetEventListeners (DOMEventType eventType)
 Returns a list of registered DOMEventHandler's for specific eventType. More...
 
List< DOMEventHandlerGetEventListeners (DOMEvent domEvent)
 Returns a list of registered DOMEventHandler's for specific custom event. More...
 
bool DispatchEvent (DOMEvent domEvent)
 Sends an event to the current element. More...
 

Detailed Description

This interface is implemented by all DOMElement that supports DOM event model.

Member Function Documentation

void DotNetBrowser.DOM.Events.DOMEventTarget.AddEventListener ( DOMEventType  eventType,
DOMEventHandler  handler,
bool  useCapture 
)

This method allows the registration of event listeners on the event target. If an DOMEventHandler is added to an DOMEventTarget while it is processing an event, it will not be triggered by the current actions but may be triggered during a later stage of event flow, such as the bubbling phase.
If multiple identical DOMEventHandlers are registered on the same DOMEventTarget with the same parameters the duplicate instances are discarded. They do not cause the DOMEventHandler to be called twice and since they are discarded they do not need to be removed with the RemoveEventListener method.

Parameters
eventTypethe event type for which the user is registering.
handlerthe handler parameter takes an interface implemented by the user which contains the methods to be called when the event occurs.
useCaptureif true, useCapture indicates that the user wishes to initiate capture. After initiating capture, all events of the specified type will be dispatched to the registered DOMEventHandler before being dispatched to any DOMEventTarget beneath them in the tree. Events which are bubbling upward through the tree will not trigger an DOMEventHandler designated to use capture.
void DotNetBrowser.DOM.Events.DOMEventTarget.AddEventListener ( DOMEvent  domEvent,
DOMEventHandler  handler,
bool  useCapture 
)

This method allows the registration of event listeners on the event target. If an DOMEventHandler is added to an DOMEventTarget while it is processing an event, it will not be triggered by the current actions but may be triggered during a later stage of event flow, such as the bubbling phase.
If multiple identical DOMEventHandlers are registered on the same DOMEventTarget with the same parameters the duplicate instances are discarded. They do not cause the DOMEventHandler to be called twice and since they are discarded they do not need to be removed with the RemoveEventListener method.

Parameters
domEventthe event for which the user is registering.
handlerthe handler parameter takes an interface implemented by the user which contains the methods to be called when the event occurs.
useCaptureif true, useCapture indicates that the user wishes to initiate capture. After initiating capture, all events of the specified type will be dispatched to the registered DOMEventHandler before being dispatched to any DOMEventTarget beneath them in the tree. Events which are bubbling upward through the tree will not trigger an DOMEventHandler designated to use capture.
bool DotNetBrowser.DOM.Events.DOMEventTarget.DispatchEvent ( DOMEvent  domEvent)

Sends an event to the current element.

Parameters
domEventspecifies the event of the DOMEventHandler.
Returns
false if event is cancelable and at least one of the event handlers which handled this event called cancelable action. Otherwise it returns true.
List<DOMEventHandler> DotNetBrowser.DOM.Events.DOMEventTarget.GetEventListeners ( DOMEventType  eventType)

Returns a list of registered DOMEventHandler's for specific eventType.

Parameters
eventTypespecifies the event type of the DOMEventHandler.
Returns
a list of registered DOMEventHandler's for specific eventType.
List<DOMEventHandler> DotNetBrowser.DOM.Events.DOMEventTarget.GetEventListeners ( DOMEvent  domEvent)

Returns a list of registered DOMEventHandler's for specific custom event.

Parameters
domEventthe event of the DOMEventHandler.
Returns
a list of registered DOMEventHandler's for specific eventType.
void DotNetBrowser.DOM.Events.DOMEventTarget.RemoveEventListener ( DOMEventType  eventType,
DOMEventHandler  handler,
bool  useCapture 
)

This method allows the removal of event listeners from the event target. If an DOMEventHandler is removed from an DOMEventTarget while it is processing an event, it will not be triggered by the current actions. DOMEventHandlers can never be invoked after being removed.
Calling RemoveEventListener with arguments which do not identify any currently registered DOMEventHandler on the DOMEventTarget has no effect.

Parameters
eventTypespecifies the event type of the DOMEventHandler being removed.
handlerthe DOMEventHandler parameter indicates the DOMEventHandler to be removed.
useCapturespecifies whether the DOMEventHandler being removed was registered as a capturing listener or not. If a listener was registered twice, one with capture and one without, each must be removed separately. Removal of a capturing listener does not affect a non-capturing version of the same listener, and vice versa.
void DotNetBrowser.DOM.Events.DOMEventTarget.RemoveEventListener ( DOMEvent  domEvent,
DOMEventHandler  handler,
bool  useCapture 
)

This method allows the removal of event listeners from the event target. If an DOMEventHandler is removed from an DOMEventTarget while it is processing an event, it will not be triggered by the current actions. DOMEventHandlers can never be invoked after being removed.
Calling RemoveEventListener with arguments which do not identify any currently registered DOMEventHandler on the DOMEventTarget has no effect.

Parameters
domEventthe event of the DOMEventHandler being removed.
handlerthe DOMEventHandler parameter indicates the DOMEventHandler to be removed.
useCapturespecifies whether the DOMEventHandler being removed was registered as a capturing listener or not. If a listener was registered twice, one with capture and one without, each must be removed separately. Removal of a capturing listener does not affect a non-capturing version of the same listener, and vice versa.