[richfaces-svn-commits] JBoss Rich Faces SVN: r6356 - trunk/sandbox/ui/inplaceSelect/src/main/resources/org/richfaces/renderkit/html/scripts.

richfaces-svn-commits at lists.jboss.org richfaces-svn-commits at lists.jboss.org
Tue Feb 26 13:54:37 EST 2008


Author: vmolotkov
Date: 2008-02-26 13:54:37 -0500 (Tue, 26 Feb 2008)
New Revision: 6356

Modified:
   trunk/sandbox/ui/inplaceSelect/src/main/resources/org/richfaces/renderkit/html/scripts/inplaceselect.js
Log:
latest changes

Modified: trunk/sandbox/ui/inplaceSelect/src/main/resources/org/richfaces/renderkit/html/scripts/inplaceselect.js
===================================================================
--- trunk/sandbox/ui/inplaceSelect/src/main/resources/org/richfaces/renderkit/html/scripts/inplaceselect.js	2008-02-26 18:01:15 UTC (rev 6355)
+++ trunk/sandbox/ui/inplaceSelect/src/main/resources/org/richfaces/renderkit/html/scripts/inplaceselect.js	2008-02-26 18:54:37 UTC (rev 6356)
@@ -17,13 +17,16 @@
 	},
 	
 	switchingStatesHandler : function($super, e) {
-		$super(e);	
-		this.tempValueKeeper.focus();
+		var el = (e.srcElement) ? e.srcElement : e.target;
+		if (el.id == this.inplaceInput.id) {
+			$super(e);
+		} else {
+			this.tempValueKeeper.focus();
+		}
 	},
 	
 	tempKeeperClickHandler : function() {
 		this.comboList.isList = false;
-		this.clickOnField = true;
 		this.comboList.showWithDelay();
 	},
 	
@@ -90,6 +93,7 @@
 			var userValue = this.comboList.activeItem.innerHTML;
 			this.tempValueKeeper.value = userValue;
 			this.comboList.selectedItem = this.comboList.activeItem;
+			//this.clickOnField = false;
 		}
 		if (!this.comboList.isList || this.clickOnBar) {
 			$super();
@@ -108,11 +112,4 @@
 	},
 	
 	setStrutWidth : function() {},
-	
-	switchingStatesHandler : function($super, e) {
-		if (!this.clickOnField) {
-			$super(e);
-		}
-		this.clickOnField = false;
-	}
 });




More information about the richfaces-svn-commits mailing list