
Ext.ux.form.Password = Ext.extend(Ext.Panel, {
	
	fieldCfg: {}
	
	,defaultFieldCfg: {
		name: 'password'
		,value: ''
		,allowBlank: true
		,tabIndex: 0
		,autoHeight: true
		,border: false
		//,blankText: 'This field is required.'
	}
	
	,getData: function () {
		return this.getEmailCmp().getValue();
	}
	
	,getEmailCmp: function () {
		return this.findByType('textfield')[0];	
	}
	
	,initComponent:function() {
		
		var baseFieldCfg = {
			xtype: 'textfield'
			,fieldLabel: 'Password'
            ,type: 'password'
			,inputType: 'password'
		};
		
		var cfg = {};
		
		Ext.apply(cfg, this.defaultFieldConfig, this.fieldCfg);	
		
		Ext.apply(cfg, baseFieldCfg);
		
		Ext.apply(this, { 
			layout: 'form'
			,border: false
			,items: [
				cfg
			]
		});
		
		Ext.ux.form.Password.superclass.initComponent.apply(this, arguments);
	}	
});	

Ext.reg('ux.form.password', Ext.ux.form.Password);
				
