Skip to content
Permalink
Browse files
Merge pull request #2206 from recena/focus
[JENKINS-33755] Better usage of focus behavior
  • Loading branch information
daniel-beck committed Apr 1, 2016
2 parents b633f88 + 9f2f827 commit 2bd03eebb6c7c89deb522a9d8375277a3d5b77d2
Showing 1 changed file with 0 additions and 3 deletions.
@@ -121,7 +121,6 @@ $.when(getItems()).done(function(data){
cleanValidationMessages('.add-item-copy');
if (isItemNameEmpty()) {
activateValidationMessage('#itemname-required', '.add-item-name');
$('input[name="name"][type="text"]', '#createItem').focus();
}
}
$item.click(setSelectState);
@@ -170,15 +169,13 @@ $.when(getItems()).done(function(data){
var message = parseResponseFromCheckJobName(data);
if (message !== '') {
activateValidationMessage('#itemname-invalid', '.add-item-name', message);
$('input[name="name"][type="text"]', '#createItem').focus();
} else {
cleanValidationMessages('.add-item-name');
showInputHelp('.add-item-name');
}
});
} else {
activateValidationMessage('#itemname-required', '.add-item-name');
$('input[name="name"][type="text"]', '#createItem').focus();
}
});

0 comments on commit 2bd03ee

Please sign in to comment.