From: john Date: Fri, 28 Sep 2018 04:38:59 +0000 (+0800) Subject: roojs-bootstrap.js X-Git-Url: http://git.roojs.org/?a=commitdiff_plain;h=9d72cab44dc9b1e081a7e30bacacdd8823dfc9f2;p=roojs1 roojs-bootstrap.js roojs-bootstrap-debug.js --- diff --git a/roojs-bootstrap-debug.js b/roojs-bootstrap-debug.js index 2c229bb24d..791df17a35 100644 --- a/roojs-bootstrap-debug.js +++ b/roojs-bootstrap-debug.js @@ -2822,27 +2822,31 @@ Roo.extend(Roo.bootstrap.Modal, Roo.bootstrap.Component, { resize : function() { - this.maskEl.setSize(Roo.lib.Dom.getViewWidth(true), Roo.lib.Dom.getViewHeight(true)); + this.maskEl.setSize( + Roo.lib.Dom.getViewWidth(true), + Roo.lib.Dom.getViewHeight(true) + ); if (this.fitwindow) { - var w = this.width || Roo.lib.Dom.getViewportWidth(true) - 30; - var h = this.height || Roo.lib.Dom.getViewportHeight(true) - 60; - this.setSize(w,h); + this.setSize( + this.width || Roo.lib.Dom.getViewportWidth(true) - 30, + this.height || Roo.lib.Dom.getViewportHeight(true) - 60 + ); + return; } - if(!this.fitwindow && this.max_width !== 0){ + Roo.log('testing'); + + if(this.max_width !== 0) { var w = Math.min(this.max_width, Roo.lib.Dom.getViewportWidth(true) - 30); - // for fix height if(this.height) { this.setSize(w, this.height); - Roo.log('this height??'); return; } if(!this.fit_content) { - Roo.log('not fitting???'); this.setSize(w, Roo.lib.Dom.getViewportHeight(true) - 60); return; } @@ -2850,14 +2854,6 @@ Roo.extend(Roo.bootstrap.Modal, Roo.bootstrap.Component, { var body_childs = this.bodyEl.dom.childNodes; var full_height = this.headerEl.getHeight() + this.footerEl.getHeight(); for(var i = 0; i < body_childs.length; i++) { - - // if(body_childs[i].classList.indexOf('roo-layout-region') * 1 != -1) { - // var layout_childs = body_childs[i].childNodes; - // for(var j = 0; j < layout_childs.length; j++) { - // - // } - // } - full_height += body_childs[i].offsetHeight; } diff --git a/roojs-bootstrap.js b/roojs-bootstrap.js index 9f3dce347a..dbb4f963dd 100644 --- a/roojs-bootstrap.js +++ b/roojs-bootstrap.js @@ -111,10 +111,10 @@ if(typeof(b.listeners)=='undefined'){b.listeners={click:this.onButtonClick.creat for(var i=0;i