Author: SergeySmirnov
Date: 2007-11-13 13:33:53 -0500 (Tue, 13 Nov 2007)
New Revision: 3964
Added:
trunk/sandbox/ui/componentControl/src/main/resources/
trunk/sandbox/ui/componentControl/src/main/resources/org/
trunk/sandbox/ui/componentControl/src/main/resources/org/richfaces/
trunk/sandbox/ui/componentControl/src/main/resources/org/richfaces/renderkit/
trunk/sandbox/ui/componentControl/src/main/resources/org/richfaces/renderkit/html/
trunk/sandbox/ui/componentControl/src/main/resources/org/richfaces/renderkit/html/script/
trunk/sandbox/ui/componentControl/src/main/resources/org/richfaces/renderkit/html/script/controlUtils.js
Log:
component/componentControl js
Added:
trunk/sandbox/ui/componentControl/src/main/resources/org/richfaces/renderkit/html/script/controlUtils.js
===================================================================
---
trunk/sandbox/ui/componentControl/src/main/resources/org/richfaces/renderkit/html/script/controlUtils.js
(rev 0)
+++
trunk/sandbox/ui/componentControl/src/main/resources/org/richfaces/renderkit/html/script/controlUtils.js 2007-11-13
18:33:53 UTC (rev 3964)
@@ -0,0 +1,22 @@
+if (!window.Richfaces) {
+window.Richfaces = {};
+}
+
+if (!Richfaces.componentControl) {
+ Richfaces.componentControl = {};
+}
+
+Richfaces.componentControl.attachEvent = function(attachTo, cevent, aevent, forAttr,
operation, params) {
+ jQuery(attachTo).bind(Richfaces.effectEventOnOut(aevent), function() {
+ jQuery( forAttr)[0].component[operation](cevent, params);
+ });
+};
+
+Richfaces.componentControl.performOperation = function( cevent, forAttr, operation,
params) {
+ jQuery( forAttr)[0].component[operation](cevent, params);
+};
+
+
+Richfaces.effectEventOnOut = function(ename) {
+ return ename.substr(0,2) == 'on' ? ename.substr(2) : ename;
+};
Show replies by date