X-Git-Url: http://git.ithinksw.org/extjs.git/blobdiff_plain/25ef3491bd9ae007ff1fc2b0d7943e6eaaccf775..10a866c12701c0a0afd0ac85dcdcf32a421514ac:/docs/source/ColumnLayout.html?ds=sidebyside diff --git a/docs/source/ColumnLayout.html b/docs/source/ColumnLayout.html index 1a6992dc..a401db94 100644 --- a/docs/source/ColumnLayout.html +++ b/docs/source/ColumnLayout.html @@ -1,17 +1,12 @@ - - - The source code - - - - -
/*!
- * Ext JS Library 3.0.3
- * Copyright(c) 2006-2009 Ext JS, LLC
- * licensing@extjs.com
- * http://www.extjs.com/license
- */
-
/** + + + + The source code + + + + +
/** * @class Ext.layout.ColumnLayout * @extends Ext.layout.ContainerLayout *

This is the layout style of choice for creating structural layouts in a multi-column format where the width of @@ -40,7 +35,7 @@ var p = new Ext.Panel({ layout:'column', items: [{ title: 'Column 1', - columnWidth: .25 + columnWidth: .25 },{ title: 'Column 2', columnWidth: .6 @@ -72,14 +67,17 @@ var p = new Ext.Panel({ Ext.layout.ColumnLayout = Ext.extend(Ext.layout.ContainerLayout, { // private monitorResize:true, - + extraCls: 'x-column', scrollOffset : 0, // private + + targetCls: 'x-column-layout-ct', + isValidParent : function(c, target){ - return (c.getPositionEl ? c.getPositionEl() : c.getEl()).dom.parentNode == this.innerCt.dom; + return c.getPositionEl().dom.parentNode == this.innerCt.dom; }, // private @@ -87,8 +85,6 @@ Ext.layout.ColumnLayout = Ext.extend(Ext.layout.ContainerLayout, { var cs = ct.items.items, len = cs.length, c, i; if(!this.innerCt){ - target.addClass('x-column-layout-ct'); - // the innerCt prevents wrapping and shuffling while // the container is resizing this.innerCt = target.createChild({cls:'x-column-inner'}); @@ -96,25 +92,25 @@ Ext.layout.ColumnLayout = Ext.extend(Ext.layout.ContainerLayout, { } this.renderAll(ct, this.innerCt); - var size = Ext.isIE && target.dom != Ext.getBody().dom ? target.getStyleSize() : target.getViewSize(); + var size = target.getViewSize(true); if(size.width < 1 && size.height < 1){ // display none? return; } - var w = size.width - target.getPadding('lr') - this.scrollOffset, - h = size.height - target.getPadding('tb'), + var w = size.width - this.scrollOffset, + h = size.height, pw = w; this.innerCt.setWidth(w); - + // some columns can be percentages while others are fixed // so we need to make 2 passes for(i = 0; i < len; i++){ c = cs[i]; if(!c.columnWidth){ - pw -= (c.getSize().width + c.getEl().getMargins('lr')); + pw -= (c.getSize().width + c.getPositionEl().getMargins('lr')); } } @@ -123,17 +119,17 @@ Ext.layout.ColumnLayout = Ext.extend(Ext.layout.ContainerLayout, { for(i = 0; i < len; i++){ c = cs[i]; if(c.columnWidth){ - c.setSize(Math.floor(c.columnWidth*pw) - c.getEl().getMargins('lr')); + c.setSize(Math.floor(c.columnWidth * pw) - c.getPositionEl().getMargins('lr')); } } } - +

/** * @property activeItem * @hide */ }); -Ext.Container.LAYOUTS['column'] = Ext.layout.ColumnLayout;
- +Ext.Container.LAYOUTS['column'] = Ext.layout.ColumnLayout;
+ \ No newline at end of file