Author: vmolotkov
Date: 2008-08-18 14:04:55 -0400 (Mon, 18 Aug 2008)
New Revision: 10131
Modified:
trunk/ui/inplaceSelect/src/main/resources/org/richfaces/renderkit/html/scripts/inplaceselect.js
trunk/ui/inplaceSelect/src/main/resources/org/richfaces/renderkit/html/scripts/inplaceselectlist.js
trunk/ui/inplaceSelect/src/main/templates/inplaceselect.jspx
Log:
https://jira.jboss.org/jira/browse/RF-4198
Modified:
trunk/ui/inplaceSelect/src/main/resources/org/richfaces/renderkit/html/scripts/inplaceselect.js
===================================================================
---
trunk/ui/inplaceSelect/src/main/resources/org/richfaces/renderkit/html/scripts/inplaceselect.js 2008-08-18
17:02:21 UTC (rev 10130)
+++
trunk/ui/inplaceSelect/src/main/resources/org/richfaces/renderkit/html/scripts/inplaceselect.js 2008-08-18
18:04:55 UTC (rev 10131)
@@ -38,14 +38,14 @@
return width;
},
- switchingStatesHandler : function($super, e) {
- var el = (e.srcElement) ? e.srcElement : e.target;
- if ((el.id == this.inplaceInput.id) || (e.type == "focus")) {
- $super(e);
- } else if(this.tempValueKeeper.style.display != "none") {
- this.tempValueKeeper.focus();
- }
- },
+ //switchingStatesHandler : function($super, e) {
+ //var el = (e.srcElement) ? e.srcElement : e.target;
+ //if (el.id == this.inplaceInput.id) {
+ //$super(e);
+ //} //else if(this.tempValueKeeper.style.display != "none") {
+ //this.tempValueKeeper.focus();
+ //}
+ //},
startEditableState : function($super) {
$super();
@@ -56,7 +56,6 @@
},
endEditableState : function($super) {
- this.inplaceInput.style.position = "";
$super();
this.button.hide();
},
@@ -69,15 +68,14 @@
buttonClickHandler : function(e) {
this.button.isClicked = true;
this.tempKeeperClickHandler();
- this.tempValueKeeper.focus();
+ //this.tempValueKeeper.focus();
Event.stop(e);
},
tmpValueBlurHandler : function($super, event) {
- if (this.clickOnBar || this.byTab || (Richfaces.browser.isIE &&
this.button.isClicked)) {
+ if (this.clickOnBar || (Richfaces.browser.isIE && this.button.isClicked)) {
//tab navigation&clickOnbar handler
this.clickOnBar = false;
- this.byTab = false;
this.button.isClicked = false;
return;
}
@@ -114,7 +112,7 @@
},
listClickHandler : function(event) {
- this.tempValueKeeper.focus();
+ //this.tempValueKeeper.focus();
this.comboList.hideWithDelay();
},
@@ -172,7 +170,6 @@
break;
case Event.KEY_TAB :
this.save();
- this.byTab = true;
break;
}
},
@@ -232,9 +229,9 @@
var text;
// IE6 support TODO: remove????
if (this.comboList.iframe) {
- text = this.inplaceInput.childNodes[7];
+ text = this.inplaceInput.childNodes[6];
} else {
- text = this.inplaceInput.childNodes[6];
+ text = this.inplaceInput.childNodes[5];
}
if (text) {
@@ -246,9 +243,9 @@
var currentText;
// IE6 support
if (this.comboList.iframe) {
- currentText = this.inplaceInput.childNodes[7];
- } else {
currentText = this.inplaceInput.childNodes[6];
+ } else {
+ currentText = this.inplaceInput.childNodes[5];
}
return currentText;
Modified:
trunk/ui/inplaceSelect/src/main/resources/org/richfaces/renderkit/html/scripts/inplaceselectlist.js
===================================================================
---
trunk/ui/inplaceSelect/src/main/resources/org/richfaces/renderkit/html/scripts/inplaceselectlist.js 2008-08-18
17:02:21 UTC (rev 10130)
+++
trunk/ui/inplaceSelect/src/main/resources/org/richfaces/renderkit/html/scripts/inplaceselectlist.js 2008-08-18
18:04:55 UTC (rev 10131)
@@ -58,7 +58,7 @@
outjectListFromBody: function(parentElement, listElement) {
if (this.listInjected) {
- var child = parentElement.insertBefore(document.body.removeChild(listElement),
parentElement.childNodes[5]);
+ var child = parentElement.insertBefore(document.body.removeChild(listElement),
parentElement.childNodes[3]);
if (Richfaces.browser.isIE6 && this.iframe) {
parentElement.insertBefore(document.body.removeChild(this.iframe), child);
}
Modified: trunk/ui/inplaceSelect/src/main/templates/inplaceselect.jspx
===================================================================
--- trunk/ui/inplaceSelect/src/main/templates/inplaceselect.jspx 2008-08-18 17:02:21 UTC
(rev 10130)
+++ trunk/ui/inplaceSelect/src/main/templates/inplaceselect.jspx 2008-08-18 18:04:55 UTC
(rev 10131)
@@ -91,10 +91,9 @@
<jsp:scriptlet>
}
</jsp:scriptlet>
- <input id="#{clientId}tabber" type="button" value=""
style="width: 1px; position: absolute; left: -32767px;"
tabindex='#{component.attributes["tabindex"]}' />
<input id="#{clientId}inplaceTmpValue"
type="text"
- style='display:none;'
+ style='clip:rect(0px 0px 10px 10px)'
value="#{fieldLabel}"
autocomplete="off"
maxlength='#{component.attributes["inputMaxLength"]}'