From aa17c81b443cbac7edc1c0ea62127320b2b7ff15 Mon Sep 17 00:00:00 2001 From: unknown Date: Fri, 15 May 2020 16:09:40 +0800 Subject: [PATCH] =?UTF-8?q?=E8=87=AA=E5=AE=9A=E4=B9=89=E6=8F=90=E4=BA=A4?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- o2web/source/o2_core/o2/xDesktop/Dialog.js | 9 ++++++++- o2web/source/x_component_process_Work/Processor.js | 12 ++++++++++-- 2 files changed, 18 insertions(+), 3 deletions(-) diff --git a/o2web/source/o2_core/o2/xDesktop/Dialog.js b/o2web/source/o2_core/o2/xDesktop/Dialog.js index 08f8a3529f..59ef88fc0d 100644 --- a/o2web/source/o2_core/o2/xDesktop/Dialog.js +++ b/o2web/source/o2_core/o2/xDesktop/Dialog.js @@ -268,7 +268,14 @@ o2.xDesktop.Dialog = o2.DDL = new Class({ this.fireEvent("restore"); }, reCenter: function(){ - var size = this.node.getSize(); + var size; + if( this.node.offsetParent === null ){ //如果是隐藏的 + size = this.node.measure(function(){ + return this.getSize(); + }); + }else{ + size = this.node.getSize(); + } if( this.options.positionWidth ){ size.x = parseInt(this.options.positionWidth); diff --git a/o2web/source/x_component_process_Work/Processor.js b/o2web/source/x_component_process_Work/Processor.js index b58f4893ab..52408b2dc8 100644 --- a/o2web/source/x_component_process_Work/Processor.js +++ b/o2web/source/x_component_process_Work/Processor.js @@ -1539,7 +1539,7 @@ MWF.xApplication.process.Work.Processor = new Class({ //var width = this.node.retrieve("width"); //empowerNode.setStyle( "width", width ); - var width = "880"; + var width = 840; //if( len > 1 ){ // width = "840" //}else{ @@ -1556,9 +1556,17 @@ MWF.xApplication.process.Work.Processor = new Class({ "isResize": false, "content": empowerNode, //"container" : this.node, - "width": width, //600, + "width": width + 40, //600, "height": "auto", //dlgHeight, "mark" : false, + "onPostLoad" : function () { + if( this.nodeWidth ){ + this.node.setStyle("width", this.nodeWidth+"px" ); + } + if( this.nodeHeight ){ + this.node.setStyle("height", this.nodeHeight+"px" ); + } + }, "buttonList": [ { "type" : "ok", -- GitLab