From: Alan Knowles Date: Fri, 5 Feb 2021 08:06:54 +0000 (+0800) Subject: fix layout height calc X-Git-Url: http://git.roojs.org/?p=roojs1;a=commitdiff_plain;h=ade0163e06142faa1968a52568612dc4d2525bc2 fix layout height calc --- diff --git a/docs/src/Roo_bootstrap_layout_Border.js.html b/docs/src/Roo_bootstrap_layout_Border.js.html index cb15bb03d5..9647fe48aa 100644 --- a/docs/src/Roo_bootstrap_layout_Border.js.html +++ b/docs/src/Roo_bootstrap_layout_Border.js.html @@ -38,7 +38,7 @@ the container size if it is not the body element.</b> }; -Roo.bootstrap.layout.Border.regions = ["north","south","east","west","center"]; +Roo.bootstrap.layout.Border.regions = ["center", "north","south","east","west"]; Roo.extend(Roo.bootstrap.layout.Border, Roo.bootstrap.layout.Manager, { diff --git a/docs/src/Roo_bootstrap_layout_East.js.html b/docs/src/Roo_bootstrap_layout_East.js.html index 66b881ec7e..52992cab10 100644 --- a/docs/src/Roo_bootstrap_layout_East.js.html +++ b/docs/src/Roo_bootstrap_layout_East.js.html @@ -8,13 +8,21 @@ this.split.orientation = Roo.bootstrap.SplitBar.HORIZONTAL; this.split.el.addClass("roo-layout-split-h"); } - var size = config.initialSize || config.width; - if(typeof size != "undefined"){ - this.el.setWidth(size); - } + }; Roo.extend(Roo.bootstrap.layout.East, Roo.bootstrap.layout.Split, { orientation: Roo.bootstrap.SplitBar.HORIZONTAL, + + onRender : function(ctr, pos) + { + Roo.bootstrap.layout.Split.prototype.onRender.call(this, ctr, pos); + var size = this.config.initialSize || this.config.width; + if(this.el && typeof size != "undefined"){ + this.el.setWidth(size); + } + + }, + getBox : function(){ if(this.collapsed){ return this.collapsedEl.getBox(); diff --git a/docs/src/Roo_bootstrap_layout_North.js.html b/docs/src/Roo_bootstrap_layout_North.js.html index 0825b1ffd2..6395f36d01 100644 --- a/docs/src/Roo_bootstrap_layout_North.js.html +++ b/docs/src/Roo_bootstrap_layout_North.js.html @@ -16,16 +16,25 @@ this.split.orientation = Roo.bootstrap.SplitBar.VERTICAL; this.split.el.addClass("roo-layout-split-v"); } - var size = config.initialSize || config.height; - if(typeof size != "undefined"){ - this.el.setHeight(size); - } -}; + //var size = config.initialSize || config.height; + //if(this.el && typeof size != "undefined"){ + // this.el.setHeight(size); + //} +}; Roo.extend(Roo.bootstrap.layout.North, Roo.bootstrap.layout.Split, { orientation: Roo.bootstrap.SplitBar.VERTICAL, + onRender : function(ctr, pos) + { + Roo.bootstrap.layout.Split.prototype.onRender.call(this, ctr, pos); + var size = this.config.initialSize || this.config.height; + if(this.el && typeof size != "undefined"){ + this.el.setHeight(size); + } + + }, getBox : function(){ if(this.collapsed){ diff --git a/docs/src/Roo_bootstrap_layout_South.js.html b/docs/src/Roo_bootstrap_layout_South.js.html index 1fc7bfa72b..f9316e9b77 100644 --- a/docs/src/Roo_bootstrap_layout_South.js.html +++ b/docs/src/Roo_bootstrap_layout_South.js.html @@ -11,14 +11,22 @@ this.split.orientation = Roo.bootstrap.SplitBar.VERTICAL; this.split.el.addClass("roo-layout-split-v"); } - var size = config.initialSize || config.height; - if(typeof size != "undefined"){ - this.el.setHeight(size); - } + }; Roo.extend(Roo.bootstrap.layout.South, Roo.bootstrap.layout.Split, { orientation: Roo.bootstrap.SplitBar.VERTICAL, + + onRender : function(ctr, pos) + { + Roo.bootstrap.layout.Split.prototype.onRender.call(this, ctr, pos); + var size = this.config.initialSize || this.config.height; + if(this.el && typeof size != "undefined"){ + this.el.setHeight(size); + } + + }, + getBox : function(){ if(this.collapsed){ return this.collapsedEl.getBox();