Browse Source

Pull request #2359: 无JIRA任务 chore: 改一下默认

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

* commit '6e65aa4d530d9dc849f1bdb4cdbc7c26413ed34d':
  chore: 改一下默认
es6
guy 3 years ago
parent
commit
b57feff4c3
  1. 9
      src/case/editor/editor.clear.js

9
src/case/editor/editor.clear.js

@ -32,6 +32,7 @@ BI.ClearEditor = BI.inherit(BI.Widget, {
this.clear = BI.createWidget({ this.clear = BI.createWidget({
type: "bi.icon_button", type: "bi.icon_button",
stopEvent: true, stopEvent: true,
invisible: BI.isKey(o.value),
cls: "search-close-h-font" cls: "search-close-h-font"
}); });
this.clear.on(BI.IconButton.EVENT_CHANGE, function () { this.clear.on(BI.IconButton.EVENT_CHANGE, function () {
@ -113,12 +114,6 @@ BI.ClearEditor = BI.inherit(BI.Widget, {
this.editor.on(BI.Editor.EVENT_STOP, function () { this.editor.on(BI.Editor.EVENT_STOP, function () {
self.fireEvent(BI.ClearEditor.EVENT_STOP); self.fireEvent(BI.ClearEditor.EVENT_STOP);
}); });
if (BI.isKey(o.value)) {
this.clear.visible();
} else {
this.clear.invisible();
}
}, },
_checkClear: function () { _checkClear: function () {
@ -179,4 +174,4 @@ BI.ClearEditor.EVENT_ENTER = "EVENT_ENTER";
BI.ClearEditor.EVENT_RESTRICT = "EVENT_RESTRICT"; BI.ClearEditor.EVENT_RESTRICT = "EVENT_RESTRICT";
BI.ClearEditor.EVENT_REMOVE = "EVENT_REMOVE"; BI.ClearEditor.EVENT_REMOVE = "EVENT_REMOVE";
BI.ClearEditor.EVENT_EMPTY = "EVENT_EMPTY"; BI.ClearEditor.EVENT_EMPTY = "EVENT_EMPTY";
BI.shortcut("bi.clear_editor", BI.ClearEditor); BI.shortcut("bi.clear_editor", BI.ClearEditor);

Loading…
Cancel
Save