From c100b7ad2b16eb977ae3eb6a6c9eb7c472e52569 Mon Sep 17 00:00:00 2001 From: guy Date: Tue, 17 Nov 2020 16:43:22 +0800 Subject: [PATCH 1/3] =?UTF-8?q?=E5=86=99=E4=B8=AAchangelog?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- changelog.md | 1 + src/core/widget.js | 2 +- 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/changelog.md b/changelog.md index a9e6ffbc7..b4173de60 100644 --- a/changelog.md +++ b/changelog.md @@ -1,5 +1,6 @@ # 更新日志 2.0(2020-11) +- store支持webworker机制,可以将状态处理多线程处理 - 修复了Popover小屏幕上看不完整的问题 - 颜色选择器支持输入16进制颜色编号 - bi.textarea_editor支持气泡提示报错 diff --git a/src/core/widget.js b/src/core/widget.js index 85f9949fa..c5aeca499 100644 --- a/src/core/widget.js +++ b/src/core/widget.js @@ -11,7 +11,7 @@ if (self[life]) { var hooks = BI.isArray(self[life]) ? self[life] : [self[life]]; BI.each(hooks, function (i, hook) { - hook.apply(self); + hook.call(self); }); } } From 703e5b47f7a8bddf280d1d896139d34e2a3b033f Mon Sep 17 00:00:00 2001 From: guy Date: Tue, 17 Nov 2020 17:34:12 +0800 Subject: [PATCH 2/3] =?UTF-8?q?children=E7=9A=84key=E5=B0=B1=E7=94=A8?= =?UTF-8?q?=E7=B4=A2=E5=BC=95=E6=9B=BF=E4=BB=A3?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/core/wrapper/layout.js | 6 +++--- src/core/wrapper/layout/layout.card.js | 2 +- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/src/core/wrapper/layout.js b/src/core/wrapper/layout.js index dc3b972b6..32f470242 100644 --- a/src/core/wrapper/layout.js +++ b/src/core/wrapper/layout.js @@ -83,7 +83,7 @@ BI.Layout = BI.inherit(BI.Widget, { }, _getChildName: function (index) { - return this.getName() + "_" + index; + return "" + index; }, _addElement: function (i, item, context) { @@ -94,7 +94,7 @@ BI.Layout = BI.inherit(BI.Widget, { BI.each(self._children, function (name, child) { if (child === w) { BI.remove(self._children, child); - self.removeItemAt(name.replace(self.getName() + "_", "") | 0); + self.removeItemAt(name | 0); } }); }); @@ -568,7 +568,7 @@ BI.Layout = BI.inherit(BI.Widget, { if (BI.isWidget(nameOrWidget)) { BI.each(this._children, function (name, child) { if (child === nameOrWidget) { - removeIndex = name.replace(self.getName() + "_", ""); + removeIndex = name; } }); } else { diff --git a/src/core/wrapper/layout/layout.card.js b/src/core/wrapper/layout/layout.card.js index b44527270..f0133de6e 100644 --- a/src/core/wrapper/layout/layout.card.js +++ b/src/core/wrapper/layout/layout.card.js @@ -196,7 +196,7 @@ BI.CardLayout = BI.inherit(BI.Layout, { if (BI.isWidget(nameOrWidget)) { BI.each(this._children, function (name, child) { if (child === nameOrWidget) { - removeName = name.replace(self.getName() + "_", ""); + removeName = name; } }); } else { From 8b18c70478c09b2e3ea40a348ff03c77b5da376f Mon Sep 17 00:00:00 2001 From: guy Date: Tue, 17 Nov 2020 17:36:28 +0800 Subject: [PATCH 3/3] =?UTF-8?q?=E5=86=99=E4=B8=AAchangelog?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- changelog.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/changelog.md b/changelog.md index b4173de60..03776318e 100644 --- a/changelog.md +++ b/changelog.md @@ -1,6 +1,6 @@ # 更新日志 2.0(2020-11) -- store支持webworker机制,可以将状态处理多线程处理 +- store支持webworker,引入多线程机制 - 修复了Popover小屏幕上看不完整的问题 - 颜色选择器支持输入16进制颜色编号 - bi.textarea_editor支持气泡提示报错