X-Git-Url: http://git.ithinksw.org/extjs.git/blobdiff_plain/c930e9176a5a85509c5b0230e2bff5c22a591432..10a866c12701c0a0afd0ac85dcdcf32a421514ac:/docs/source/ColumnLayout.html
diff --git a/docs/source/ColumnLayout.html b/docs/source/ColumnLayout.html
index 5c2ca15f..a401db94 100644
--- a/docs/source/ColumnLayout.html
+++ b/docs/source/ColumnLayout.html
@@ -1,5 +1,6 @@
+
The source code
@@ -34,7 +35,7 @@ var p = new Ext.Panel({
layout:'column',
items: [{
title: 'Column 1',
- columnWidth: .25
+ columnWidth: .25
},{
title: 'Column 2',
columnWidth: .6
@@ -66,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
@@ -81,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'});
@@ -90,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'));
}
}
@@ -117,11 +119,11 @@ 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