PDA

View Full Version : Problem with FormPanel's tabs



marianorauch
19 Jun 2008, 1:31 PM
I need help with formpanel in adobe air app.
I have login form with user and password fields.
My problem is the tabs between user field and pasword field.
I need pressing twice tab.

Thank you for your help.

My application has :
var win = new Ext.air.NativeWindow({
id: 'idlogin',
file: 'login.html',
width: 300,
height:150,
maximizable: false,
resizable: false
});

win.getNative().alwaysInFront = true;

And login page is:

<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>Page - Login</title>

<link rel="stylesheet" type="text/css" href="js/ext-2.1/resources/css/ext-all.css" />
<link rel="stylesheet" type="text/css" href="js/ext-2.1/air/resources/ext-air.css" />

<script type="text/javascript" src="js/AIRAliases.js"></script>
<script type="text/javascript" src="js/AIRIntrospector.js"></script>
<script type="text/javascript" src="js/jquery-1.2.6.min.js"></script>
<script type="text/javascript" src="js/ext-2.1/adapter/ext/ext-base.js"></script>
<script type="text/javascript" src="js/ext-2.1/ext-all.js"></script>
<script type="text/javascript" src="js/ext-2.1/air/ext-air.js"></script>

<script type="text/javascript" src="js/app/login.js"></script>

</head>
<body>
<script type="text/javascript">

var win = window.nativeWindow;

var fsf = new Ext.form.FormPanel({
url:'save-form.php',
frame:true,
region: 'center',
//title: 'Login',
//bodyStyle:'padding:5px 5px 0',
width: 350,
heigth: 500,
defaultType: 'textfield',
items: [{
fieldLabel: 'User',
name: 'user',
id: 'fuser'
//allowBlank:false
},{
fieldLabel: 'Password',
name: 'password',
id: 'fpassword',
//allowBlank:false,
inputType:'password'
}],
buttons: [{
text: 'Send',
handler: function(){
var usr = fsf.findById('fuser').getValue();
var passw = fsf.findById('fpassword').getValue();
app.login.login(usr, passw);
}
}]
});

var nav = new Ext.Panel({
title: '',
//region: 'center',
frame: true,
width: 350,
heigth:200,
items: [fsf,
{xtype: 'box',
autoEl: { html:"<div align='right'><a href='' onclick='javascript:openLink(\"http://www.homepage.com/\");' >New Account Signup</a></div>"}
}]
});

//fsf.render(document.body);
var viewport = new Ext.Viewport({
layout:'fit',
items:[nav]
});

win.visible = true;
win.activate();
</script>
</body>
</html>
http://extjs.com/forum/images/misc/progress.gif http://extjs.com/forum/images/buttons/edit.gif (http://extjs.com/forum/editpost.php?do=editpost&p=184294)

marianorauch
20 Jun 2008, 12:14 PM
The problem was fixed.
the AIRIntrospector.js has problem with event of Ext.
I delete line :
<script type="text/javascript" src="js/AIRIntrospector.js"></script>

and the login form run well.

See you.