/*
 * Ext JS Library 1.1.1
 * Copyright(c) 2006-2007, Ext JS, LLC.
 * licensing@extjs.com
 * 
 * http://www.extjs.com/license
 */

Ext.form.Layout=function(A){Ext.form.Layout.superclass.constructor.call(this,A);this.stack=[]};Ext.extend(Ext.form.Layout,Ext.Component,{clear:true,labelSeparator:":",hideLabels:false,defaultAutoCreate:{tag:"div",cls:"x-form-ct"},onRender:function(F,B){if(this.el){this.el=Ext.get(this.el)}else{var C=this.getAutoCreate();this.el=F.createChild(C,B)}if(this.style){this.el.applyStyles(this.style)}if(this.labelAlign){this.el.addClass("x-form-label-"+this.labelAlign)}if(this.hideLabels){this.labelStyle="display:none";this.elementStyle="padding-left:0;"}else{if(typeof this.labelWidth=="number"){this.labelStyle="width:"+this.labelWidth+"px;";this.elementStyle="padding-left:"+((this.labelWidth+(typeof this.labelPad=="number"?this.labelPad:5))+"px")+";"}if(this.labelAlign=="top"){this.labelStyle="width:auto;";this.elementStyle="padding-left:0;"}}var A=this.stack;var G=A.length;if(G>0){if(!this.fieldTpl){var E=new Ext.Template("<div class=\"x-form-item {5}\">","<label for=\"{0}\" style=\"{2}\">{1}{4}</label>","<div class=\"x-form-element\" id=\"x-form-el-{0}\" style=\"{3}\">","</div>","</div><div class=\"x-form-clear-left\"></div>");E.disableFormats=true;E.compile();Ext.form.Layout.prototype.fieldTpl=E}for(var D=0;D<G;D++){if(A[D].isFormField){this.renderField(A[D])}else{this.renderComponent(A[D])}}}if(this.clear){this.el.createChild({cls:"x-form-clear"})}},renderField:function(A){this.fieldTpl.append(this.el,[A.id,A.fieldLabel,A.labelStyle||this.labelStyle||"",this.elementStyle||"",typeof A.labelSeparator=="undefined"?this.labelSeparator:A.labelSeparator,A.itemCls||this.itemCls||""])},renderComponent:function(A){A.render(this.el)}});Ext.form.Column=function(A){Ext.form.Column.superclass.constructor.call(this,A)};Ext.extend(Ext.form.Column,Ext.form.Layout,{defaultAutoCreate:{tag:"div",cls:"x-form-ct x-form-column"},onRender:function(B,A){Ext.form.Column.superclass.onRender.call(this,B,A);if(this.width){this.el.setWidth(this.width)}}});Ext.form.FieldSet=function(A){Ext.form.FieldSet.superclass.constructor.call(this,A)};Ext.extend(Ext.form.FieldSet,Ext.form.Layout,{defaultAutoCreate:{tag:"fieldset",cn:{tag:"legend"}},onRender:function(B,A){Ext.form.FieldSet.superclass.onRender.call(this,B,A);if(this.legend){this.setLegend(this.legend)}},setLegend:function(A){if(this.rendered){this.el.child("legend").update(A)}}});