Browse Source

Pull request #1587: 无JIRA任务 写个changelog

Merge in VISUAL/fineui from ~GUY/fineui:master to master

* commit '8b18c70478c09b2e3ea40a348ff03c77b5da376f':
  写个changelog
  children的key就用索引替代
  写个changelog
es6
guy 4 years ago
parent
commit
b2f44a89e2
  1. 1
      changelog.md
  2. 2
      src/core/widget.js
  3. 6
      src/core/wrapper/layout.js
  4. 2
      src/core/wrapper/layout/layout.card.js

1
changelog.md

@ -1,5 +1,6 @@
# 更新日志 # 更新日志
2.0(2020-11) 2.0(2020-11)
- store支持webworker,引入多线程机制
- 修复了Popover小屏幕上看不完整的问题 - 修复了Popover小屏幕上看不完整的问题
- 颜色选择器支持输入16进制颜色编号 - 颜色选择器支持输入16进制颜色编号
- bi.textarea_editor支持气泡提示报错 - bi.textarea_editor支持气泡提示报错

2
src/core/widget.js

@ -11,7 +11,7 @@
if (self[life]) { if (self[life]) {
var hooks = BI.isArray(self[life]) ? self[life] : [self[life]]; var hooks = BI.isArray(self[life]) ? self[life] : [self[life]];
BI.each(hooks, function (i, hook) { BI.each(hooks, function (i, hook) {
hook.apply(self); hook.call(self);
}); });
} }
} }

6
src/core/wrapper/layout.js

@ -83,7 +83,7 @@ BI.Layout = BI.inherit(BI.Widget, {
}, },
_getChildName: function (index) { _getChildName: function (index) {
return this.getName() + "_" + index; return "" + index;
}, },
_addElement: function (i, item, context) { _addElement: function (i, item, context) {
@ -94,7 +94,7 @@ BI.Layout = BI.inherit(BI.Widget, {
BI.each(self._children, function (name, child) { BI.each(self._children, function (name, child) {
if (child === w) { if (child === w) {
BI.remove(self._children, child); 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)) { if (BI.isWidget(nameOrWidget)) {
BI.each(this._children, function (name, child) { BI.each(this._children, function (name, child) {
if (child === nameOrWidget) { if (child === nameOrWidget) {
removeIndex = name.replace(self.getName() + "_", ""); removeIndex = name;
} }
}); });
} else { } else {

2
src/core/wrapper/layout/layout.card.js

@ -196,7 +196,7 @@ BI.CardLayout = BI.inherit(BI.Layout, {
if (BI.isWidget(nameOrWidget)) { if (BI.isWidget(nameOrWidget)) {
BI.each(this._children, function (name, child) { BI.each(this._children, function (name, child) {
if (child === nameOrWidget) { if (child === nameOrWidget) {
removeName = name.replace(self.getName() + "_", ""); removeName = name;
} }
}); });
} else { } else {

Loading…
Cancel
Save