Class Index | File Index

## Classes

- _global_
- Accordion
- AccordionItem
- CollapsiblePanel
- jQuery
- PanelMenu
- PanelMenuGroup
- PanelMenuItem
- RichFaces
- RichFaces.ajaxContainer
- RichFaces.BaseComponent
- RichFaces.Event
- RichFaces.queue
- TabPanel
- TogglePanel
- Tooltip

# Namespace RichFaces.Event

Defined in: richfaces-event.js.

Namespace Summary
Constructor Attributes | Constructor Name and Description
--- | ---
| RichFaces.Event RichFaces Event API container

Field Summary
Field Attributes | Field Name and Description
--- | ---
<static> <constant> | RichFaces.Event.EVENT_NAMESPACE_SEPARATOR

Method Summary
Method Attributes | Method Name and Description
--- | ---
<static> | RichFaces.Event.bind(selector, eventType, fn, data) Attach a handler to an event for the elements.
<static> | RichFaces.Event.bindById(id, eventType, fn, data) Attach a handler to an event for the element by element id.
<static> | RichFaces.Event.bindOne(selector, eventType, fn, data) Attach a handler to an event for the elements.
<static> | RichFaces.Event.bindOneById(id, eventType, fn, data) Attach a handler to an event for the element by element id.
<static> | RichFaces.Event.callHandler(selector, eventType, data) The same as the fire method, but: - does not cause the default behavior of an event to occur - does not bubble up event - call handler only for the first founded element - returns whatever value that was returned by the handler
<static> | RichFaces.Event.callHandlerById(id, eventType, data) The same as the callHandler method, but selects element by id.
<static> | RichFaces.Event.createNamespace(componentName, id, prefix) Create an event namespace for the components.
<static> | RichFaces.Event.fire(selector, eventType, data) Execute all handlers and behaviors attached to the matched elements for the given event type.
<static> | RichFaces.Event.fireById(id, eventType, data) The same as the fire method, but selects element by id.
<static> | RichFaces.Event.ready(fn) Attach an event handler to execute when the DOM is fully loaded.
<static> | RichFaces.Event.unbind(selector, eventType, fn) Remove a previously-attached event handler from the elements.
<static> | RichFaces.Event.unbindById(id, eventType, fn) Remove a previously-attached event handler from the elements by element id.

Namespace Detail
RichFaces.Event
RichFaces Event API container
Field Detail
<static> <constant> {string} RichFaces.Event.EVENT_NAMESPACE_SEPARATOR
Method Detail
<static> {function} RichFaces.Event.bind(selector, eventType, fn, data)
Attach a handler to an event for the elements.

Parameters:
{string|DOMElement|jQuery} selector
  - jQuery elements selector
{string} eventType
  - one or more JavaScript event types, such as "click" or "submit," or custom event names
{function} fn
  - event handler
{Object} data Optional
  - component or object with additional data It is a context for an event handler

Returns:
  {function} function that binded to the element's event

<static> {function} RichFaces.Event.bindById(id, eventType, fn, data)
Attach a handler to an event for the element by element id.

Parameters:
{string} id
  - DOM element id
{string} eventType
  - one or more JavaScript event types, such as "click" or "submit," or custom event names
{function} fn
  - event handler
{Object} data Optional
  - component or object with additional data It is a context for an event handler

Returns:
  {function} function that binded to the element's event

<static> {function} RichFaces.Event.bindOne(selector, eventType, fn, data)
Attach a handler to an event for the elements. The handler will be called only once when event happened.

Parameters:
{string|DOMElement|jQuery} selector
  - jQuery elements selector
{string} eventType
  - one or more JavaScript event types, such as "click" or "submit," or custom event names
{function} fn
  - event handler
{Object} data Optional
  - component or object with additional data It is a context for an event handler

Returns:
  {function} function that binded to the element's event

<static> {function} RichFaces.Event.bindOneById(id, eventType, fn, data)
Attach a handler to an event for the element by element id. The handler will be called only once when event happened.

Parameters:
{string} id
  - DOM element id
{string} eventType
  - one or more JavaScript event types, such as "click" or "submit," or custom event names
{function} fn
  - event handler
{Object} data Optional
  - component or object with additional data It is a context for an event handler

Returns:
  {function} function that binded to the element's event

<static> RichFaces.Event.callHandler(selector, eventType, data)
The same as the fire method, but: - does not cause the default behavior of an event to occur - does not bubble up event - call handler only for the first founded element - returns whatever value that was returned by the handler

Parameters:
{string|DOMElement|jQuery} selector
  - jQuery elements selector
{string} eventType
  - event type
{Object} data Optional
  - a object of additional parameters to pass to the event handler

Returns:
  value that was returned by the handler

<static> RichFaces.Event.callHandlerById(id, eventType, data)
The same as the callHandler method, but selects element by id.

Parameters:
{string} id
  - DOM element id
{string} eventType
  - event type
{Object} data Optional
  - a object of additional parameters to pass to the event handler

Returns:
  value that was returned by the handler

<static> {string} RichFaces.Event.createNamespace(componentName, id, prefix)
Create an event namespace for the components.

Parameters:
{string} componentName Optional
  - component name
{string} id Optional
  - element id
{string} prefix Optional, Default: RichFaces.Event.RICH_NAMESPACE
  - namespace prefix

Returns:
  {string} namespace string

<static> {jQuery} RichFaces.Event.fire(selector, eventType, data)
Execute all handlers and behaviors attached to the matched elements for the given event type.

Parameters:
{string|DOMElement|jQuery} selector
  - jQuery elements selector
{string} eventType
  - event type
{Object} data Optional
  - a object of additional parameters to pass to the event handler

Returns:
  {jQuery} element wrapped by jQuery

<static> {jQuery} RichFaces.Event.fireById(id, eventType, data)
The same as the fire method, but selects element by id.

Parameters:
{string} id
  - DOM element id
{string} eventType
  - event type
{Object} data Optional
  - a object of additional parameters to pass to the event handler

Returns:
  {jQuery} element wrapped by jQuery

<static> {jQuery} RichFaces.Event.ready(fn)
Attach an event handler to execute when the DOM is fully loaded.

Parameters:
{function} fn
  - event handler

Returns:
  {jQuery} document element wrapped by jQuery

<static> {jQuery} RichFaces.Event.unbind(selector, eventType, fn)
Remove a previously-attached event handler from the elements.

Parameters:
{string|DOMElement|jQuery} selector
  - jQuery elements selector
{string} eventType Optional
  - one or more JavaScript event types, such as "click" or "submit," or custom event names
{function} fn Optional
  - event handler

Returns:
  {jQuery} element wrapped by jQuery

<static> {jQuery} RichFaces.Event.unbindById(id, eventType, fn)
Remove a previously-attached event handler from the elements by element id. The handler will be called only once when event happened.

Parameters:
{string} id
  - DOM element id
{string} eventType Optional
  - one or more JavaScript event types, such as "click" or "submit," or custom event names
{function} fn Optional
  - event handler

Returns:
  {jQuery} element wrapped by jQuery

Documentation generated by JsDoc Toolkit 2.0.0 on Wed May 29 2013 12:03:32 GMT+0200 (CEST)