From 229d84e514314c7514cd148c5700a0e66a9658de Mon Sep 17 00:00:00 2001 From: Sebastian Sdorra Date: Tue, 7 Sep 2010 18:12:00 +0200 Subject: [PATCH] set focus on username field --- .../src/main/webapp/resources/js/sonia.login.js | 15 ++++++++++----- 1 file changed, 10 insertions(+), 5 deletions(-) diff --git a/scm-webapp/src/main/webapp/resources/js/sonia.login.js b/scm-webapp/src/main/webapp/resources/js/sonia.login.js index a7a3ed2f6a..7807bac971 100644 --- a/scm-webapp/src/main/webapp/resources/js/sonia.login.js +++ b/scm-webapp/src/main/webapp/resources/js/sonia.login.js @@ -10,12 +10,17 @@ Sonia.login.Form = Ext.extend(Ext.FormPanel,{ initComponent: function(){ var config = { - labelWidth:80, + labelWidth: 80, url: restUrl + "authentication.json", - frame:true, - title:'Please Login', - defaultType:'textfield', - monitorValid:true, + frame: true, + title: 'Please Login', + defaultType: 'textfield', + monitorValid: true, + listeners: { + afterrender: function(){ + Ext.getCmp('username').focus(true, 500); + } + }, items:[{ id: 'username', fieldLabel:'Username',