/*
* handling focus for navigation.
*/
function handlingFocus(attributeIds) {
return function settingFocus(evt) {
keyCode = evt.getKeyCode();
var arrayLength = attributeIds.length;
var temp1 = 0;
if (keyCode == AdfKeyStroke.TAB_KEY) {
while (arrayLength != 0) {
var lastField = evt.getSource();
var firstField = lastField.findComponent(attributeIds[temp1]);
if (!firstField.getProperty("disabled")) {
firstField.focus();
evt.cancel();
break;
}
else{
//alert('Please pass the valid Ids as argument');
firstField = lastField.findComponent(attributeIds[arrayLength-1]);
firstField.focus();
evt.cancel();
}
temp1++;
arrayLength--;
}
}
}
}
* handling focus for navigation.
*/
function handlingFocus(attributeIds) {
return function settingFocus(evt) {
keyCode = evt.getKeyCode();
var arrayLength = attributeIds.length;
var temp1 = 0;
if (keyCode == AdfKeyStroke.TAB_KEY) {
while (arrayLength != 0) {
var lastField = evt.getSource();
var firstField = lastField.findComponent(attributeIds[temp1]);
if (!firstField.getProperty("disabled")) {
firstField.focus();
evt.cancel();
break;
}
else{
//alert('Please pass the valid Ids as argument');
firstField = lastField.findComponent(attributeIds[arrayLength-1]);
firstField.focus();
evt.cancel();
}
temp1++;
arrayLength--;
}
}
}
}
No comments:
Post a Comment