X-Git-Url: http://git.ithinksw.org/extjs.git/blobdiff_plain/c930e9176a5a85509c5b0230e2bff5c22a591432..10a866c12701c0a0afd0ac85dcdcf32a421514ac:/docs/source/TableLayout.html?ds=sidebyside diff --git a/docs/source/TableLayout.html b/docs/source/TableLayout.html index da8a5da3..f396e3bc 100644 --- a/docs/source/TableLayout.html +++ b/docs/source/TableLayout.html @@ -1,5 +1,6 @@ + The source code @@ -73,6 +74,8 @@ Ext.layout.TableLayout = Ext.extend(Ext.layout.ContainerLayout, { // private monitorResize:false, + + targetCls: 'x-table-layout-ct',
/** * @cfg {Object} tableAttrs @@ -107,8 +110,6 @@ Ext.layout.TableLayout = Ext.extend(Ext.layout.ContainerLayout, { var cs = ct.items.items, len = cs.length, c, i; if(!this.table){ - target.addClass('x-table-layout-ct'); - this.table = target.createChild( Ext.apply({tag:'table', cls:'x-table-layout', cellspacing: 0, cn: {tag: 'tbody'}}, this.tableAttrs), null, true); } @@ -174,16 +175,18 @@ Ext.layout.TableLayout = Ext.extend(Ext.layout.ContainerLayout, { renderItem : function(c, position, target){ if(c && !c.rendered){ c.render(this.getNextCell(c)); - if(this.extraCls){ - var t = c.getPositionEl ? c.getPositionEl() : c; - t.addClass(this.extraCls); - } + this.configureItem(c, position); + }else if(c && !this.isValidParent(c, target)){ + var container = this.getNextCell(c); + container.insertBefore(c.getPositionEl().dom, null); + c.container = Ext.get(container); + this.configureItem(c, position); } }, // private isValidParent : function(c, target){ - return true; + return c.getPositionEl().up('table', 5).dom.parentNode === (target.dom || target); }
/**