Author: pyaschenko
Date: 2010-12-03 11:00:27 -0500 (Fri, 03 Dec 2010)
New Revision: 20365
Modified:
trunk/core/impl/src/main/resources/META-INF/resources/richfaces-event.js
Log:
http://jira.jboss.com/jira/browse/RF-9858
Modified: trunk/core/impl/src/main/resources/META-INF/resources/richfaces-event.js
===================================================================
--- trunk/core/impl/src/main/resources/META-INF/resources/richfaces-event.js 2010-12-03
15:36:35 UTC (rev 20364)
+++ trunk/core/impl/src/main/resources/META-INF/resources/richfaces-event.js 2010-12-03
16:00:27 UTC (rev 20365)
@@ -94,9 +94,14 @@
* */
bind : function(selector, eventType, fn, component, data) {
// eventType: namespace can be used, like onclick.rf.conponentName
- var f = getHandlerWrapper(component, fn);
- getEventElement(selector).bind(eventType, data, f);
- return f;
+ if (typeof eventType == "object") {
+ // in this case fn == component object
+ getEventElement(selector).bind(getMultipleHandlerWrapper(eventType, fn), data);
+ } else {
+ var f = getHandlerWrapper(component, fn);
+ getEventElement(selector).bind(eventType, data, f);
+ return f;
+ }
},
/**