From eebb3d53a314687557cebb8c87c4e1a2dd26e92b Mon Sep 17 00:00:00 2001 From: john Date: Wed, 26 Sep 2018 11:21:10 +0800 Subject: [PATCH] Roo/bootstrap/Modal.js --- Roo/bootstrap/Modal.js | 14 ++++++++++++-- 1 file changed, 12 insertions(+), 2 deletions(-) diff --git a/Roo/bootstrap/Modal.js b/Roo/bootstrap/Modal.js index 59ea3de75c..7b85926fa1 100644 --- a/Roo/bootstrap/Modal.js +++ b/Roo/bootstrap/Modal.js @@ -270,8 +270,18 @@ Roo.extend(Roo.bootstrap.Modal, Roo.bootstrap.Component, { if(!this.fitwindow && this.max_width !== 0){ var w = Math.min(this.max_width, Roo.lib.Dom.getViewportWidth(true) - 30); - var h = this.height || Roo.lib.Dom.getViewportHeight(true) - 60; - this.setSize(w,h); + // var h = this.height || Roo.lib.Dom.getViewportHeight(true) - 60; + this.setSize(w,this.height); + + if( + ( + this.headerEl.getHeight() + + this.bodyEl.getHeight() + + this.footerEl.getHeight() + ) > Roo.lib.Dom.getViewportHeight(true) - 60) { + } { + + } } }, -- 2.39.2