From 36dd2ba61c6054bb5b47c077b27cde77850aa8cf Mon Sep 17 00:00:00 2001 From: guy Date: Mon, 7 Mar 2022 11:00:13 +0800 Subject: [PATCH] =?UTF-8?q?feature=EF=BC=9A=20disabled?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/core/4.widget.js | 3 +++ 1 file changed, 3 insertions(+) diff --git a/src/core/4.widget.js b/src/core/4.widget.js index 119afda59..c9260bdb3 100644 --- a/src/core/4.widget.js +++ b/src/core/4.widget.js @@ -570,6 +570,9 @@ throw new Error("组件:组件名已存在,不能进行添加"); } widget._setParent && widget._setParent(this); + if(!this.isEnabled()){ + widget._setEnable(false); + } widget.on(BI.Events.DESTROY, function () { BI.remove(self._children, this); });