guy 7 years ago
parent
commit
2e7939f682
  1. 6
      demo/js/base/button/demo.button.js
  2. 8
      demo/js/case/combo/demo.icon_combo.js
  3. 6
      demo/js/case/combo/demo.icon_text_value_combo.js
  4. 6
      demo/js/case/combo/demo.text_value_combo.js
  5. 6
      demo/js/widget/basewidget/demo.buttons.js
  6. 6
      dist/base.js
  7. 62
      dist/bundle.js
  8. 20
      dist/bundle.min.js
  9. 45
      dist/case.js
  10. 32
      dist/demo.js
  11. 62
      dist/fineui.js
  12. 28
      dist/fineui.min.js
  13. 11
      dist/widget.js
  14. 6
      src/base/single/button/buttons/button.js
  15. 10
      src/case/button/icon/icon.change.js
  16. 5
      src/case/button/item.singleselect.icontext.js
  17. 4
      src/case/combo/iconcombo/combo.icon.js
  18. 14
      src/case/combo/iconcombo/trigger.iconcombo.js
  19. 2
      src/case/trigger/trigger.icon.text.js
  20. 10
      src/case/trigger/trigger.icon.text.select.js
  21. 3
      src/widget/downlist/combo.downlist.js
  22. 8
      src/widget/numberinterval/numberinterval.js

6
demo/js/base/button/demo.button.js

@ -54,7 +54,7 @@ Demo.Button = BI.inherit(BI.Widget, {
type: "bi.button", type: "bi.button",
text: "带图标的按钮", text: "带图标的按钮",
// level: 'ignore', // level: 'ignore',
iconClass: "close-font", iconCls: "close-font",
height: 30 height: 30
} }
}, { }, {
@ -114,7 +114,7 @@ Demo.Button = BI.inherit(BI.Widget, {
text: "带图标的按钮", text: "带图标的按钮",
block: true, block: true,
// level: 'ignore', // level: 'ignore',
iconClass: "close-font", iconCls: "close-font",
height: 30 height: 30
} }
}, { }, {
@ -174,7 +174,7 @@ Demo.Button = BI.inherit(BI.Widget, {
text: "带图标的按钮", text: "带图标的按钮",
clear: true, clear: true,
// level: 'ignore', // level: 'ignore',
iconClass: "close-font", iconCls: "close-font",
height: 30 height: 30
} }
}, { }, {

8
demo/js/case/combo/demo.icon_combo.js

@ -19,16 +19,16 @@ Demo.IconCombo = BI.inherit(BI.Widget, {
ref: function (_ref) { ref: function (_ref) {
self.refs = _ref; self.refs = _ref;
}, },
iconClass: "search-font", iconCls: "search-font",
items: [{ items: [{
value: "第一项", value: "第一项",
iconClass: "close-font" iconCls: "close-font"
}, { }, {
value: "第二项", value: "第二项",
iconClass: "search-font" iconCls: "search-font"
}, { }, {
value: "第三项", value: "第三项",
iconClass: "copy-font" iconCls: "copy-font"
}] }]
}], }],
vgap: 20 vgap: 20

6
demo/js/case/combo/demo.icon_text_value_combo.js

@ -16,15 +16,15 @@ Demo.IconTextValueCombo = BI.inherit(BI.Widget, {
width: 300, width: 300,
items: [{ items: [{
text: "MVC-1", text: "MVC-1",
iconClass: "close-font", iconCls: "close-font",
value: 1 value: 1
}, { }, {
text: "MVC-2", text: "MVC-2",
iconClass: "date-font", iconCls: "date-font",
value: 2 value: 2
}, { }, {
text: "MVC-3", text: "MVC-3",
iconClass: "search-close-h-font", iconCls: "search-close-h-font",
value: 3 value: 3
}] }]
}], }],

6
demo/js/case/combo/demo.text_value_combo.js

@ -15,15 +15,15 @@ Demo.TextValueCombo = BI.inherit(BI.Widget, {
width: 300, width: 300,
items: [{ items: [{
text: "MVC-1", text: "MVC-1",
iconClass: "date-font", iconCls: "date-font",
value: 1 value: 1
}, { }, {
text: "MVC-2", text: "MVC-2",
iconClass: "search-font", iconCls: "search-font",
value: 2 value: 2
}, { }, {
text: "MVC-3", text: "MVC-3",
iconClass: "pull-right-font", iconCls: "pull-right-font",
value: 3 value: 3
}] }]
}], }],

6
demo/js/widget/basewidget/demo.buttons.js

@ -58,7 +58,7 @@ Demo.Buttons = BI.inherit(BI.Widget, {
type: "bi.button", type: "bi.button",
text: "带图标的按钮", text: "带图标的按钮",
// level: 'ignore', // level: 'ignore',
iconClass: "close-font", iconCls: "close-font",
height: 30 height: 30
} }
}, { }, {
@ -118,7 +118,7 @@ Demo.Buttons = BI.inherit(BI.Widget, {
text: "带图标的按钮", text: "带图标的按钮",
block: true, block: true,
// level: 'ignore', // level: 'ignore',
iconClass: "close-font", iconCls: "close-font",
height: 30 height: 30
} }
}, { }, {
@ -178,7 +178,7 @@ Demo.Buttons = BI.inherit(BI.Widget, {
text: "带图标的按钮", text: "带图标的按钮",
clear: true, clear: true,
// level: 'ignore', // level: 'ignore',
iconClass: "close-font", iconCls: "close-font",
height: 30 height: 30
} }
}, { }, {

6
dist/base.js vendored

@ -16432,7 +16432,7 @@ BI.shortcut("bi.image_button", BI.ImageButton);(function ($) {
shadow: props.clear !== true, shadow: props.clear !== true,
isShadowShowingOnSelected: true, isShadowShowingOnSelected: true,
readonly: true, readonly: true,
iconClass: "", iconCls: "",
level: "common", level: "common",
block: false, // 是否块状显示,即不显示边框,没有最小宽度的限制 block: false, // 是否块状显示,即不显示边框,没有最小宽度的限制
clear: false, // 是否去掉边框和背景 clear: false, // 是否去掉边框和背景
@ -16458,7 +16458,7 @@ BI.shortcut("bi.image_button", BI.ImageButton);(function ($) {
} else { } else {
this.element.css({lineHeight: o.height + "px"}); this.element.css({lineHeight: o.height + "px"});
} }
if (BI.isKey(o.iconClass)) { if (BI.isKey(o.iconCls)) {
this.icon = BI.createWidget({ this.icon = BI.createWidget({
type: "bi.icon", type: "bi.icon",
width: 18 width: 18
@ -16470,7 +16470,7 @@ BI.shortcut("bi.image_button", BI.ImageButton);(function ($) {
}); });
BI.createWidget({ BI.createWidget({
type: "bi.horizontal_auto", type: "bi.horizontal_auto",
cls: o.iconClass, cls: o.iconCls,
element: this, element: this,
hgap: o.hgap, hgap: o.hgap,
vgap: o.vgap, vgap: o.vgap,

62
dist/bundle.js vendored

@ -42305,7 +42305,7 @@ BI.shortcut("bi.image_button", BI.ImageButton);(function ($) {
shadow: props.clear !== true, shadow: props.clear !== true,
isShadowShowingOnSelected: true, isShadowShowingOnSelected: true,
readonly: true, readonly: true,
iconClass: "", iconCls: "",
level: "common", level: "common",
block: false, // 是否块状显示,即不显示边框,没有最小宽度的限制 block: false, // 是否块状显示,即不显示边框,没有最小宽度的限制
clear: false, // 是否去掉边框和背景 clear: false, // 是否去掉边框和背景
@ -42331,7 +42331,7 @@ BI.shortcut("bi.image_button", BI.ImageButton);(function ($) {
} else { } else {
this.element.css({lineHeight: o.height + "px"}); this.element.css({lineHeight: o.height + "px"});
} }
if (BI.isKey(o.iconClass)) { if (BI.isKey(o.iconCls)) {
this.icon = BI.createWidget({ this.icon = BI.createWidget({
type: "bi.icon", type: "bi.icon",
width: 18 width: 18
@ -42343,7 +42343,7 @@ BI.shortcut("bi.image_button", BI.ImageButton);(function ($) {
}); });
BI.createWidget({ BI.createWidget({
type: "bi.horizontal_auto", type: "bi.horizontal_auto",
cls: o.iconClass, cls: o.iconCls,
element: this, element: this,
hgap: o.hgap, hgap: o.hgap,
vgap: o.vgap, vgap: o.vgap,
@ -62251,7 +62251,7 @@ BI.IconChangeButton = BI.inherit(BI.Single, {
var conf = BI.IconChangeButton.superclass._defaultConfig.apply(this, arguments); var conf = BI.IconChangeButton.superclass._defaultConfig.apply(this, arguments);
return BI.extend(conf, { return BI.extend(conf, {
baseCls: "bi-icon-change-button", baseCls: "bi-icon-change-button",
iconClass: "", iconCls: "",
iconWidth: null, iconWidth: null,
iconHeight: null, iconHeight: null,
@ -62276,7 +62276,7 @@ BI.IconChangeButton = BI.inherit(BI.Single, {
this.button = BI.createWidget({ this.button = BI.createWidget({
type: "bi.icon_button", type: "bi.icon_button",
element: this, element: this,
cls: o.iconClass, cls: o.iconCls,
height: o.height, height: o.height,
iconWidth: o.iconWidth, iconWidth: o.iconWidth,
iconHeight: o.iconHeight, iconHeight: o.iconHeight,
@ -62313,9 +62313,9 @@ BI.IconChangeButton = BI.inherit(BI.Single, {
setIcon: function (cls) { setIcon: function (cls) {
var o = this.options; var o = this.options;
if (o.iconClass !== cls) { if (o.iconCls !== cls) {
this.element.removeClass(o.iconClass).addClass(cls); this.element.removeClass(o.iconCls).addClass(cls);
o.iconClass = cls; o.iconCls = cls;
} }
} }
}); });
@ -62464,8 +62464,7 @@ BI.SingleSelectIconTextItem = BI.inherit(BI.Single, {
_defaultConfig: function () { _defaultConfig: function () {
return BI.extend(BI.SingleSelectIconTextItem.superclass._defaultConfig.apply(this, arguments), { return BI.extend(BI.SingleSelectIconTextItem.superclass._defaultConfig.apply(this, arguments), {
extraCls: "bi-single-select-icon-text-item bi-list-item-active", extraCls: "bi-single-select-icon-text-item bi-list-item-active",
iconClass: "", iconCls: "",
hgap: 10,
height: 25 height: 25
}); });
}, },
@ -62475,7 +62474,7 @@ BI.SingleSelectIconTextItem = BI.inherit(BI.Single, {
this.text = BI.createWidget({ this.text = BI.createWidget({
type: "bi.icon_text_item", type: "bi.icon_text_item",
element: this, element: this,
cls: o.iconClass, cls: o.iconCls,
once: o.once, once: o.once,
selected: o.selected, selected: o.selected,
height: o.height, height: o.height,
@ -67443,7 +67442,7 @@ BI.IconCombo = BI.inherit(BI.Widget, {
baseCls: "bi-icon-combo", baseCls: "bi-icon-combo",
width: 24, width: 24,
height: 24, height: 24,
iconClass: "", iconCls: "",
el: {}, el: {},
popup: {}, popup: {},
minWidth: 100, minWidth: 100,
@ -67463,7 +67462,7 @@ BI.IconCombo = BI.inherit(BI.Widget, {
var self = this, o = this.options; var self = this, o = this.options;
this.trigger = BI.createWidget(o.el, { this.trigger = BI.createWidget(o.el, {
type: "bi.icon_combo_trigger", type: "bi.icon_combo_trigger",
iconClass: o.iconClass, iconCls: o.iconCls,
title: o.title, title: o.title,
items: o.items, items: o.items,
width: o.width, width: o.width,
@ -67600,7 +67599,7 @@ BI.IconComboTrigger = BI.inherit(BI.Trigger, {
extraCls: "bi-icon-combo-trigger", extraCls: "bi-icon-combo-trigger",
el: {}, el: {},
items: [], items: [],
iconClass: "", iconCls: "",
width: 25, width: 25,
height: 25, height: 25,
isShowDown: true isShowDown: true
@ -67612,7 +67611,7 @@ BI.IconComboTrigger = BI.inherit(BI.Trigger, {
var o = this.options, self = this; var o = this.options, self = this;
this.button = BI.createWidget(o.el, { this.button = BI.createWidget(o.el, {
type: "bi.icon_change_button", type: "bi.icon_change_button",
cls: "icon-combo-trigger-icon " + o.iconClass, cls: "icon-combo-trigger-icon " + o.iconCls,
disableSelected: true, disableSelected: true,
width: o.width, width: o.width,
height: o.height, height: o.height,
@ -67650,7 +67649,7 @@ BI.IconComboTrigger = BI.inherit(BI.Trigger, {
populate: function (items) { populate: function (items) {
var o = this.options; var o = this.options;
this.options.items = items || []; this.options.items = items || [];
this.button.setIcon(o.iconClass); this.button.setIcon(o.iconCls);
this.button.setSelected(false); this.button.setSelected(false);
this.down.setSelected(false); this.down.setSelected(false);
}, },
@ -67658,19 +67657,19 @@ BI.IconComboTrigger = BI.inherit(BI.Trigger, {
setValue: function (v) { setValue: function (v) {
BI.IconComboTrigger.superclass.setValue.apply(this, arguments); BI.IconComboTrigger.superclass.setValue.apply(this, arguments);
var o = this.options; var o = this.options;
var iconClass = ""; var iconCls = "";
v = BI.isArray(v) ? v[0] : v; v = BI.isArray(v) ? v[0] : v;
if (BI.any(this.options.items, function (i, item) { if (BI.any(this.options.items, function (i, item) {
if (v === item.value) { if (v === item.value) {
iconClass = item.iconClass; iconCls = item.iconCls;
return true; return true;
} }
})) { })) {
this.button.setIcon(iconClass); this.button.setIcon(iconCls);
this.button.setSelected(true); this.button.setSelected(true);
this.down.setSelected(true); this.down.setSelected(true);
} else { } else {
this.button.setIcon(o.iconClass); this.button.setIcon(o.iconCls);
this.button.setSelected(false); this.button.setSelected(false);
this.down.setSelected(false); this.down.setSelected(false);
} }
@ -75961,7 +75960,7 @@ BI.IconTextTrigger = BI.inherit(BI.Trigger, {
items: [{ items: [{
el: { el: {
type: "bi.icon_change_button", type: "bi.icon_change_button",
cls: "icon-combo-trigger-icon " + o.iconClass, cls: "icon-combo-trigger-icon " + o.iconCls,
ref: function (_ref) { ref: function (_ref) {
self.icon = _ref; self.icon = _ref;
}, },
@ -76025,7 +76024,7 @@ BI.SelectIconTextTrigger = BI.inherit(BI.Trigger, {
type: "bi.icon_text_trigger", type: "bi.icon_text_trigger",
element: this, element: this,
text: obj.text, text: obj.text,
iconClass: obj.iconClass, iconCls: obj.iconCls,
height: o.height height: o.height
}); });
}, },
@ -76039,7 +76038,7 @@ BI.SelectIconTextTrigger = BI.inherit(BI.Trigger, {
if (BI.deepContains(vals, item.value)) { if (BI.deepContains(vals, item.value)) {
result = { result = {
text: item.text || item.value, text: item.text || item.value,
iconClass: item.iconClass iconCls: item.iconCls
}; };
return true; return true;
} }
@ -76048,12 +76047,12 @@ BI.SelectIconTextTrigger = BI.inherit(BI.Trigger, {
if (BI.isNotNull(result)) { if (BI.isNotNull(result)) {
return { return {
text: result.text, text: result.text,
iconClass: result.iconClass iconCls: result.iconCls
}; };
} else { } else {
return { return {
text: o.text, text: o.text,
iconClass: "" iconCls: ""
}; };
} }
}, },
@ -76061,7 +76060,7 @@ BI.SelectIconTextTrigger = BI.inherit(BI.Trigger, {
setValue: function (vals) { setValue: function (vals) {
var obj = this._digist(vals, this.options.items); var obj = this._digist(vals, this.options.items);
this.trigger.setText(obj.text); this.trigger.setText(obj.text);
this.trigger.setIcon(obj.iconClass); this.trigger.setIcon(obj.iconCls);
}, },
populate: function (items) { populate: function (items) {
@ -79756,8 +79755,7 @@ BI.DownListCombo = BI.inherit(BI.Widget, {
_defaultConfig: function () { _defaultConfig: function () {
return BI.extend(BI.DownListCombo.superclass._defaultConfig.apply(this, arguments), { return BI.extend(BI.DownListCombo.superclass._defaultConfig.apply(this, arguments), {
baseCls: "bi-down-list-combo", baseCls: "bi-down-list-combo",
invalid: false, height: 24,
height: 25,
items: [], items: [],
adjustLength: 0, adjustLength: 0,
direction: "bottom", direction: "bottom",
@ -89270,12 +89268,12 @@ BI.NumberInterval = BI.inherit(BI.Single, {
height: o.height - 2, height: o.height - 2,
items: [{ items: [{
text: "(" + BI.i18nText("BI-Less_Than") + ")", text: "(" + BI.i18nText("BI-Less_Than") + ")",
iconClass: "less-font", iconCls: "less-font",
value: 0 value: 0
}, { }, {
text: "(" + BI.i18nText("BI-Less_And_Equal") + ")", text: "(" + BI.i18nText("BI-Less_And_Equal") + ")",
value: 1, value: 1,
iconClass: "less-equal-font" iconCls: "less-equal-font"
}] }]
}); });
if (o.closemin === true) { if (o.closemin === true) {
@ -89289,12 +89287,12 @@ BI.NumberInterval = BI.inherit(BI.Single, {
height: o.height - 2, height: o.height - 2,
items: [{ items: [{
text: "(" + BI.i18nText("BI-Less_Than") + ")", text: "(" + BI.i18nText("BI-Less_Than") + ")",
iconClass: "less-font", iconCls: "less-font",
value: 0 value: 0
}, { }, {
text: "(" + BI.i18nText("BI-Less_And_Equal") + ")", text: "(" + BI.i18nText("BI-Less_And_Equal") + ")",
value: 1, value: 1,
iconClass: "less-equal-font" iconCls: "less-equal-font"
}] }]
}); });
if (o.closemax === true) { if (o.closemax === true) {

20
dist/bundle.min.js vendored

File diff suppressed because one or more lines are too long

45
dist/case.js vendored

@ -11,7 +11,7 @@ BI.IconChangeButton = BI.inherit(BI.Single, {
var conf = BI.IconChangeButton.superclass._defaultConfig.apply(this, arguments); var conf = BI.IconChangeButton.superclass._defaultConfig.apply(this, arguments);
return BI.extend(conf, { return BI.extend(conf, {
baseCls: "bi-icon-change-button", baseCls: "bi-icon-change-button",
iconClass: "", iconCls: "",
iconWidth: null, iconWidth: null,
iconHeight: null, iconHeight: null,
@ -36,7 +36,7 @@ BI.IconChangeButton = BI.inherit(BI.Single, {
this.button = BI.createWidget({ this.button = BI.createWidget({
type: "bi.icon_button", type: "bi.icon_button",
element: this, element: this,
cls: o.iconClass, cls: o.iconCls,
height: o.height, height: o.height,
iconWidth: o.iconWidth, iconWidth: o.iconWidth,
iconHeight: o.iconHeight, iconHeight: o.iconHeight,
@ -73,9 +73,9 @@ BI.IconChangeButton = BI.inherit(BI.Single, {
setIcon: function (cls) { setIcon: function (cls) {
var o = this.options; var o = this.options;
if (o.iconClass !== cls) { if (o.iconCls !== cls) {
this.element.removeClass(o.iconClass).addClass(cls); this.element.removeClass(o.iconCls).addClass(cls);
o.iconClass = cls; o.iconCls = cls;
} }
} }
}); });
@ -224,8 +224,7 @@ BI.SingleSelectIconTextItem = BI.inherit(BI.Single, {
_defaultConfig: function () { _defaultConfig: function () {
return BI.extend(BI.SingleSelectIconTextItem.superclass._defaultConfig.apply(this, arguments), { return BI.extend(BI.SingleSelectIconTextItem.superclass._defaultConfig.apply(this, arguments), {
extraCls: "bi-single-select-icon-text-item bi-list-item-active", extraCls: "bi-single-select-icon-text-item bi-list-item-active",
iconClass: "", iconCls: "",
hgap: 10,
height: 25 height: 25
}); });
}, },
@ -235,7 +234,7 @@ BI.SingleSelectIconTextItem = BI.inherit(BI.Single, {
this.text = BI.createWidget({ this.text = BI.createWidget({
type: "bi.icon_text_item", type: "bi.icon_text_item",
element: this, element: this,
cls: o.iconClass, cls: o.iconCls,
once: o.once, once: o.once,
selected: o.selected, selected: o.selected,
height: o.height, height: o.height,
@ -5203,7 +5202,7 @@ BI.IconCombo = BI.inherit(BI.Widget, {
baseCls: "bi-icon-combo", baseCls: "bi-icon-combo",
width: 24, width: 24,
height: 24, height: 24,
iconClass: "", iconCls: "",
el: {}, el: {},
popup: {}, popup: {},
minWidth: 100, minWidth: 100,
@ -5223,7 +5222,7 @@ BI.IconCombo = BI.inherit(BI.Widget, {
var self = this, o = this.options; var self = this, o = this.options;
this.trigger = BI.createWidget(o.el, { this.trigger = BI.createWidget(o.el, {
type: "bi.icon_combo_trigger", type: "bi.icon_combo_trigger",
iconClass: o.iconClass, iconCls: o.iconCls,
title: o.title, title: o.title,
items: o.items, items: o.items,
width: o.width, width: o.width,
@ -5360,7 +5359,7 @@ BI.IconComboTrigger = BI.inherit(BI.Trigger, {
extraCls: "bi-icon-combo-trigger", extraCls: "bi-icon-combo-trigger",
el: {}, el: {},
items: [], items: [],
iconClass: "", iconCls: "",
width: 25, width: 25,
height: 25, height: 25,
isShowDown: true isShowDown: true
@ -5372,7 +5371,7 @@ BI.IconComboTrigger = BI.inherit(BI.Trigger, {
var o = this.options, self = this; var o = this.options, self = this;
this.button = BI.createWidget(o.el, { this.button = BI.createWidget(o.el, {
type: "bi.icon_change_button", type: "bi.icon_change_button",
cls: "icon-combo-trigger-icon " + o.iconClass, cls: "icon-combo-trigger-icon " + o.iconCls,
disableSelected: true, disableSelected: true,
width: o.width, width: o.width,
height: o.height, height: o.height,
@ -5410,7 +5409,7 @@ BI.IconComboTrigger = BI.inherit(BI.Trigger, {
populate: function (items) { populate: function (items) {
var o = this.options; var o = this.options;
this.options.items = items || []; this.options.items = items || [];
this.button.setIcon(o.iconClass); this.button.setIcon(o.iconCls);
this.button.setSelected(false); this.button.setSelected(false);
this.down.setSelected(false); this.down.setSelected(false);
}, },
@ -5418,19 +5417,19 @@ BI.IconComboTrigger = BI.inherit(BI.Trigger, {
setValue: function (v) { setValue: function (v) {
BI.IconComboTrigger.superclass.setValue.apply(this, arguments); BI.IconComboTrigger.superclass.setValue.apply(this, arguments);
var o = this.options; var o = this.options;
var iconClass = ""; var iconCls = "";
v = BI.isArray(v) ? v[0] : v; v = BI.isArray(v) ? v[0] : v;
if (BI.any(this.options.items, function (i, item) { if (BI.any(this.options.items, function (i, item) {
if (v === item.value) { if (v === item.value) {
iconClass = item.iconClass; iconCls = item.iconCls;
return true; return true;
} }
})) { })) {
this.button.setIcon(iconClass); this.button.setIcon(iconCls);
this.button.setSelected(true); this.button.setSelected(true);
this.down.setSelected(true); this.down.setSelected(true);
} else { } else {
this.button.setIcon(o.iconClass); this.button.setIcon(o.iconCls);
this.button.setSelected(false); this.button.setSelected(false);
this.down.setSelected(false); this.down.setSelected(false);
} }
@ -13721,7 +13720,7 @@ BI.IconTextTrigger = BI.inherit(BI.Trigger, {
items: [{ items: [{
el: { el: {
type: "bi.icon_change_button", type: "bi.icon_change_button",
cls: "icon-combo-trigger-icon " + o.iconClass, cls: "icon-combo-trigger-icon " + o.iconCls,
ref: function (_ref) { ref: function (_ref) {
self.icon = _ref; self.icon = _ref;
}, },
@ -13785,7 +13784,7 @@ BI.SelectIconTextTrigger = BI.inherit(BI.Trigger, {
type: "bi.icon_text_trigger", type: "bi.icon_text_trigger",
element: this, element: this,
text: obj.text, text: obj.text,
iconClass: obj.iconClass, iconCls: obj.iconCls,
height: o.height height: o.height
}); });
}, },
@ -13799,7 +13798,7 @@ BI.SelectIconTextTrigger = BI.inherit(BI.Trigger, {
if (BI.deepContains(vals, item.value)) { if (BI.deepContains(vals, item.value)) {
result = { result = {
text: item.text || item.value, text: item.text || item.value,
iconClass: item.iconClass iconCls: item.iconCls
}; };
return true; return true;
} }
@ -13808,12 +13807,12 @@ BI.SelectIconTextTrigger = BI.inherit(BI.Trigger, {
if (BI.isNotNull(result)) { if (BI.isNotNull(result)) {
return { return {
text: result.text, text: result.text,
iconClass: result.iconClass iconCls: result.iconCls
}; };
} else { } else {
return { return {
text: o.text, text: o.text,
iconClass: "" iconCls: ""
}; };
} }
}, },
@ -13821,7 +13820,7 @@ BI.SelectIconTextTrigger = BI.inherit(BI.Trigger, {
setValue: function (vals) { setValue: function (vals) {
var obj = this._digist(vals, this.options.items); var obj = this._digist(vals, this.options.items);
this.trigger.setText(obj.text); this.trigger.setText(obj.text);
this.trigger.setIcon(obj.iconClass); this.trigger.setIcon(obj.iconCls);
}, },
populate: function (items) { populate: function (items) {

32
dist/demo.js vendored

@ -73,7 +73,7 @@ $(function () {
type: "bi.button", type: "bi.button",
text: "带图标的按钮", text: "带图标的按钮",
// level: 'ignore', // level: 'ignore',
iconClass: "close-font", iconCls: "close-font",
height: 30 height: 30
} }
}, { }, {
@ -133,7 +133,7 @@ $(function () {
text: "带图标的按钮", text: "带图标的按钮",
block: true, block: true,
// level: 'ignore', // level: 'ignore',
iconClass: "close-font", iconCls: "close-font",
height: 30 height: 30
} }
}, { }, {
@ -193,7 +193,7 @@ $(function () {
text: "带图标的按钮", text: "带图标的按钮",
clear: true, clear: true,
// level: 'ignore', // level: 'ignore',
iconClass: "close-font", iconCls: "close-font",
height: 30 height: 30
} }
}, { }, {
@ -1801,16 +1801,16 @@ Demo.IconCombo = BI.inherit(BI.Widget, {
ref: function (_ref) { ref: function (_ref) {
self.refs = _ref; self.refs = _ref;
}, },
iconClass: "search-font", iconCls: "search-font",
items: [{ items: [{
value: "第一项", value: "第一项",
iconClass: "close-font" iconCls: "close-font"
}, { }, {
value: "第二项", value: "第二项",
iconClass: "search-font" iconCls: "search-font"
}, { }, {
value: "第三项", value: "第三项",
iconClass: "copy-font" iconCls: "copy-font"
}] }]
}], }],
vgap: 20 vgap: 20
@ -1836,15 +1836,15 @@ Demo.IconTextValueCombo = BI.inherit(BI.Widget, {
width: 300, width: 300,
items: [{ items: [{
text: "MVC-1", text: "MVC-1",
iconClass: "close-font", iconCls: "close-font",
value: 1 value: 1
}, { }, {
text: "MVC-2", text: "MVC-2",
iconClass: "date-font", iconCls: "date-font",
value: 2 value: 2
}, { }, {
text: "MVC-3", text: "MVC-3",
iconClass: "search-close-h-font", iconCls: "search-close-h-font",
value: 3 value: 3
}] }]
}], }],
@ -1914,15 +1914,15 @@ Demo.TextValueCombo = BI.inherit(BI.Widget, {
width: 300, width: 300,
items: [{ items: [{
text: "MVC-1", text: "MVC-1",
iconClass: "date-font", iconCls: "date-font",
value: 1 value: 1
}, { }, {
text: "MVC-2", text: "MVC-2",
iconClass: "search-font", iconCls: "search-font",
value: 2 value: 2
}, { }, {
text: "MVC-3", text: "MVC-3",
iconClass: "pull-right-font", iconCls: "pull-right-font",
value: 3 value: 3
}] }]
}], }],
@ -11727,7 +11727,7 @@ Demo.Buttons = BI.inherit(BI.Widget, {
type: "bi.button", type: "bi.button",
text: "带图标的按钮", text: "带图标的按钮",
// level: 'ignore', // level: 'ignore',
iconClass: "close-font", iconCls: "close-font",
height: 30 height: 30
} }
}, { }, {
@ -11787,7 +11787,7 @@ Demo.Buttons = BI.inherit(BI.Widget, {
text: "带图标的按钮", text: "带图标的按钮",
block: true, block: true,
// level: 'ignore', // level: 'ignore',
iconClass: "close-font", iconCls: "close-font",
height: 30 height: 30
} }
}, { }, {
@ -11847,7 +11847,7 @@ Demo.Buttons = BI.inherit(BI.Widget, {
text: "带图标的按钮", text: "带图标的按钮",
clear: true, clear: true,
// level: 'ignore', // level: 'ignore',
iconClass: "close-font", iconCls: "close-font",
height: 30 height: 30
} }
}, { }, {

62
dist/fineui.js vendored

@ -43999,7 +43999,7 @@ BI.shortcut("bi.image_button", BI.ImageButton);(function ($) {
shadow: props.clear !== true, shadow: props.clear !== true,
isShadowShowingOnSelected: true, isShadowShowingOnSelected: true,
readonly: true, readonly: true,
iconClass: "", iconCls: "",
level: "common", level: "common",
block: false, // 是否块状显示,即不显示边框,没有最小宽度的限制 block: false, // 是否块状显示,即不显示边框,没有最小宽度的限制
clear: false, // 是否去掉边框和背景 clear: false, // 是否去掉边框和背景
@ -44025,7 +44025,7 @@ BI.shortcut("bi.image_button", BI.ImageButton);(function ($) {
} else { } else {
this.element.css({lineHeight: o.height + "px"}); this.element.css({lineHeight: o.height + "px"});
} }
if (BI.isKey(o.iconClass)) { if (BI.isKey(o.iconCls)) {
this.icon = BI.createWidget({ this.icon = BI.createWidget({
type: "bi.icon", type: "bi.icon",
width: 18 width: 18
@ -44037,7 +44037,7 @@ BI.shortcut("bi.image_button", BI.ImageButton);(function ($) {
}); });
BI.createWidget({ BI.createWidget({
type: "bi.horizontal_auto", type: "bi.horizontal_auto",
cls: o.iconClass, cls: o.iconCls,
element: this, element: this,
hgap: o.hgap, hgap: o.hgap,
vgap: o.vgap, vgap: o.vgap,
@ -63945,7 +63945,7 @@ BI.IconChangeButton = BI.inherit(BI.Single, {
var conf = BI.IconChangeButton.superclass._defaultConfig.apply(this, arguments); var conf = BI.IconChangeButton.superclass._defaultConfig.apply(this, arguments);
return BI.extend(conf, { return BI.extend(conf, {
baseCls: "bi-icon-change-button", baseCls: "bi-icon-change-button",
iconClass: "", iconCls: "",
iconWidth: null, iconWidth: null,
iconHeight: null, iconHeight: null,
@ -63970,7 +63970,7 @@ BI.IconChangeButton = BI.inherit(BI.Single, {
this.button = BI.createWidget({ this.button = BI.createWidget({
type: "bi.icon_button", type: "bi.icon_button",
element: this, element: this,
cls: o.iconClass, cls: o.iconCls,
height: o.height, height: o.height,
iconWidth: o.iconWidth, iconWidth: o.iconWidth,
iconHeight: o.iconHeight, iconHeight: o.iconHeight,
@ -64007,9 +64007,9 @@ BI.IconChangeButton = BI.inherit(BI.Single, {
setIcon: function (cls) { setIcon: function (cls) {
var o = this.options; var o = this.options;
if (o.iconClass !== cls) { if (o.iconCls !== cls) {
this.element.removeClass(o.iconClass).addClass(cls); this.element.removeClass(o.iconCls).addClass(cls);
o.iconClass = cls; o.iconCls = cls;
} }
} }
}); });
@ -64158,8 +64158,7 @@ BI.SingleSelectIconTextItem = BI.inherit(BI.Single, {
_defaultConfig: function () { _defaultConfig: function () {
return BI.extend(BI.SingleSelectIconTextItem.superclass._defaultConfig.apply(this, arguments), { return BI.extend(BI.SingleSelectIconTextItem.superclass._defaultConfig.apply(this, arguments), {
extraCls: "bi-single-select-icon-text-item bi-list-item-active", extraCls: "bi-single-select-icon-text-item bi-list-item-active",
iconClass: "", iconCls: "",
hgap: 10,
height: 25 height: 25
}); });
}, },
@ -64169,7 +64168,7 @@ BI.SingleSelectIconTextItem = BI.inherit(BI.Single, {
this.text = BI.createWidget({ this.text = BI.createWidget({
type: "bi.icon_text_item", type: "bi.icon_text_item",
element: this, element: this,
cls: o.iconClass, cls: o.iconCls,
once: o.once, once: o.once,
selected: o.selected, selected: o.selected,
height: o.height, height: o.height,
@ -69137,7 +69136,7 @@ BI.IconCombo = BI.inherit(BI.Widget, {
baseCls: "bi-icon-combo", baseCls: "bi-icon-combo",
width: 24, width: 24,
height: 24, height: 24,
iconClass: "", iconCls: "",
el: {}, el: {},
popup: {}, popup: {},
minWidth: 100, minWidth: 100,
@ -69157,7 +69156,7 @@ BI.IconCombo = BI.inherit(BI.Widget, {
var self = this, o = this.options; var self = this, o = this.options;
this.trigger = BI.createWidget(o.el, { this.trigger = BI.createWidget(o.el, {
type: "bi.icon_combo_trigger", type: "bi.icon_combo_trigger",
iconClass: o.iconClass, iconCls: o.iconCls,
title: o.title, title: o.title,
items: o.items, items: o.items,
width: o.width, width: o.width,
@ -69294,7 +69293,7 @@ BI.IconComboTrigger = BI.inherit(BI.Trigger, {
extraCls: "bi-icon-combo-trigger", extraCls: "bi-icon-combo-trigger",
el: {}, el: {},
items: [], items: [],
iconClass: "", iconCls: "",
width: 25, width: 25,
height: 25, height: 25,
isShowDown: true isShowDown: true
@ -69306,7 +69305,7 @@ BI.IconComboTrigger = BI.inherit(BI.Trigger, {
var o = this.options, self = this; var o = this.options, self = this;
this.button = BI.createWidget(o.el, { this.button = BI.createWidget(o.el, {
type: "bi.icon_change_button", type: "bi.icon_change_button",
cls: "icon-combo-trigger-icon " + o.iconClass, cls: "icon-combo-trigger-icon " + o.iconCls,
disableSelected: true, disableSelected: true,
width: o.width, width: o.width,
height: o.height, height: o.height,
@ -69344,7 +69343,7 @@ BI.IconComboTrigger = BI.inherit(BI.Trigger, {
populate: function (items) { populate: function (items) {
var o = this.options; var o = this.options;
this.options.items = items || []; this.options.items = items || [];
this.button.setIcon(o.iconClass); this.button.setIcon(o.iconCls);
this.button.setSelected(false); this.button.setSelected(false);
this.down.setSelected(false); this.down.setSelected(false);
}, },
@ -69352,19 +69351,19 @@ BI.IconComboTrigger = BI.inherit(BI.Trigger, {
setValue: function (v) { setValue: function (v) {
BI.IconComboTrigger.superclass.setValue.apply(this, arguments); BI.IconComboTrigger.superclass.setValue.apply(this, arguments);
var o = this.options; var o = this.options;
var iconClass = ""; var iconCls = "";
v = BI.isArray(v) ? v[0] : v; v = BI.isArray(v) ? v[0] : v;
if (BI.any(this.options.items, function (i, item) { if (BI.any(this.options.items, function (i, item) {
if (v === item.value) { if (v === item.value) {
iconClass = item.iconClass; iconCls = item.iconCls;
return true; return true;
} }
})) { })) {
this.button.setIcon(iconClass); this.button.setIcon(iconCls);
this.button.setSelected(true); this.button.setSelected(true);
this.down.setSelected(true); this.down.setSelected(true);
} else { } else {
this.button.setIcon(o.iconClass); this.button.setIcon(o.iconCls);
this.button.setSelected(false); this.button.setSelected(false);
this.down.setSelected(false); this.down.setSelected(false);
} }
@ -77655,7 +77654,7 @@ BI.IconTextTrigger = BI.inherit(BI.Trigger, {
items: [{ items: [{
el: { el: {
type: "bi.icon_change_button", type: "bi.icon_change_button",
cls: "icon-combo-trigger-icon " + o.iconClass, cls: "icon-combo-trigger-icon " + o.iconCls,
ref: function (_ref) { ref: function (_ref) {
self.icon = _ref; self.icon = _ref;
}, },
@ -77719,7 +77718,7 @@ BI.SelectIconTextTrigger = BI.inherit(BI.Trigger, {
type: "bi.icon_text_trigger", type: "bi.icon_text_trigger",
element: this, element: this,
text: obj.text, text: obj.text,
iconClass: obj.iconClass, iconCls: obj.iconCls,
height: o.height height: o.height
}); });
}, },
@ -77733,7 +77732,7 @@ BI.SelectIconTextTrigger = BI.inherit(BI.Trigger, {
if (BI.deepContains(vals, item.value)) { if (BI.deepContains(vals, item.value)) {
result = { result = {
text: item.text || item.value, text: item.text || item.value,
iconClass: item.iconClass iconCls: item.iconCls
}; };
return true; return true;
} }
@ -77742,12 +77741,12 @@ BI.SelectIconTextTrigger = BI.inherit(BI.Trigger, {
if (BI.isNotNull(result)) { if (BI.isNotNull(result)) {
return { return {
text: result.text, text: result.text,
iconClass: result.iconClass iconCls: result.iconCls
}; };
} else { } else {
return { return {
text: o.text, text: o.text,
iconClass: "" iconCls: ""
}; };
} }
}, },
@ -77755,7 +77754,7 @@ BI.SelectIconTextTrigger = BI.inherit(BI.Trigger, {
setValue: function (vals) { setValue: function (vals) {
var obj = this._digist(vals, this.options.items); var obj = this._digist(vals, this.options.items);
this.trigger.setText(obj.text); this.trigger.setText(obj.text);
this.trigger.setIcon(obj.iconClass); this.trigger.setIcon(obj.iconCls);
}, },
populate: function (items) { populate: function (items) {
@ -81450,8 +81449,7 @@ BI.DownListCombo = BI.inherit(BI.Widget, {
_defaultConfig: function () { _defaultConfig: function () {
return BI.extend(BI.DownListCombo.superclass._defaultConfig.apply(this, arguments), { return BI.extend(BI.DownListCombo.superclass._defaultConfig.apply(this, arguments), {
baseCls: "bi-down-list-combo", baseCls: "bi-down-list-combo",
invalid: false, height: 24,
height: 25,
items: [], items: [],
adjustLength: 0, adjustLength: 0,
direction: "bottom", direction: "bottom",
@ -90964,12 +90962,12 @@ BI.NumberInterval = BI.inherit(BI.Single, {
height: o.height - 2, height: o.height - 2,
items: [{ items: [{
text: "(" + BI.i18nText("BI-Less_Than") + ")", text: "(" + BI.i18nText("BI-Less_Than") + ")",
iconClass: "less-font", iconCls: "less-font",
value: 0 value: 0
}, { }, {
text: "(" + BI.i18nText("BI-Less_And_Equal") + ")", text: "(" + BI.i18nText("BI-Less_And_Equal") + ")",
value: 1, value: 1,
iconClass: "less-equal-font" iconCls: "less-equal-font"
}] }]
}); });
if (o.closemin === true) { if (o.closemin === true) {
@ -90983,12 +90981,12 @@ BI.NumberInterval = BI.inherit(BI.Single, {
height: o.height - 2, height: o.height - 2,
items: [{ items: [{
text: "(" + BI.i18nText("BI-Less_Than") + ")", text: "(" + BI.i18nText("BI-Less_Than") + ")",
iconClass: "less-font", iconCls: "less-font",
value: 0 value: 0
}, { }, {
text: "(" + BI.i18nText("BI-Less_And_Equal") + ")", text: "(" + BI.i18nText("BI-Less_And_Equal") + ")",
value: 1, value: 1,
iconClass: "less-equal-font" iconCls: "less-equal-font"
}] }]
}); });
if (o.closemax === true) { if (o.closemax === true) {

28
dist/fineui.min.js vendored

File diff suppressed because one or more lines are too long

11
dist/widget.js vendored

@ -3457,8 +3457,7 @@ BI.DownListCombo = BI.inherit(BI.Widget, {
_defaultConfig: function () { _defaultConfig: function () {
return BI.extend(BI.DownListCombo.superclass._defaultConfig.apply(this, arguments), { return BI.extend(BI.DownListCombo.superclass._defaultConfig.apply(this, arguments), {
baseCls: "bi-down-list-combo", baseCls: "bi-down-list-combo",
invalid: false, height: 24,
height: 25,
items: [], items: [],
adjustLength: 0, adjustLength: 0,
direction: "bottom", direction: "bottom",
@ -12971,12 +12970,12 @@ BI.NumberInterval = BI.inherit(BI.Single, {
height: o.height - 2, height: o.height - 2,
items: [{ items: [{
text: "(" + BI.i18nText("BI-Less_Than") + ")", text: "(" + BI.i18nText("BI-Less_Than") + ")",
iconClass: "less-font", iconCls: "less-font",
value: 0 value: 0
}, { }, {
text: "(" + BI.i18nText("BI-Less_And_Equal") + ")", text: "(" + BI.i18nText("BI-Less_And_Equal") + ")",
value: 1, value: 1,
iconClass: "less-equal-font" iconCls: "less-equal-font"
}] }]
}); });
if (o.closemin === true) { if (o.closemin === true) {
@ -12990,12 +12989,12 @@ BI.NumberInterval = BI.inherit(BI.Single, {
height: o.height - 2, height: o.height - 2,
items: [{ items: [{
text: "(" + BI.i18nText("BI-Less_Than") + ")", text: "(" + BI.i18nText("BI-Less_Than") + ")",
iconClass: "less-font", iconCls: "less-font",
value: 0 value: 0
}, { }, {
text: "(" + BI.i18nText("BI-Less_And_Equal") + ")", text: "(" + BI.i18nText("BI-Less_And_Equal") + ")",
value: 1, value: 1,
iconClass: "less-equal-font" iconCls: "less-equal-font"
}] }]
}); });
if (o.closemax === true) { if (o.closemax === true) {

6
src/base/single/button/buttons/button.js

@ -18,7 +18,7 @@
shadow: props.clear !== true, shadow: props.clear !== true,
isShadowShowingOnSelected: true, isShadowShowingOnSelected: true,
readonly: true, readonly: true,
iconClass: "", iconCls: "",
level: "common", level: "common",
block: false, // 是否块状显示,即不显示边框,没有最小宽度的限制 block: false, // 是否块状显示,即不显示边框,没有最小宽度的限制
clear: false, // 是否去掉边框和背景 clear: false, // 是否去掉边框和背景
@ -44,7 +44,7 @@
} else { } else {
this.element.css({lineHeight: o.height + "px"}); this.element.css({lineHeight: o.height + "px"});
} }
if (BI.isKey(o.iconClass)) { if (BI.isKey(o.iconCls)) {
this.icon = BI.createWidget({ this.icon = BI.createWidget({
type: "bi.icon", type: "bi.icon",
width: 18 width: 18
@ -56,7 +56,7 @@
}); });
BI.createWidget({ BI.createWidget({
type: "bi.horizontal_auto", type: "bi.horizontal_auto",
cls: o.iconClass, cls: o.iconCls,
element: this, element: this,
hgap: o.hgap, hgap: o.hgap,
vgap: o.vgap, vgap: o.vgap,

10
src/case/button/icon/icon.change.js

@ -11,7 +11,7 @@ BI.IconChangeButton = BI.inherit(BI.Single, {
var conf = BI.IconChangeButton.superclass._defaultConfig.apply(this, arguments); var conf = BI.IconChangeButton.superclass._defaultConfig.apply(this, arguments);
return BI.extend(conf, { return BI.extend(conf, {
baseCls: "bi-icon-change-button", baseCls: "bi-icon-change-button",
iconClass: "", iconCls: "",
iconWidth: null, iconWidth: null,
iconHeight: null, iconHeight: null,
@ -36,7 +36,7 @@ BI.IconChangeButton = BI.inherit(BI.Single, {
this.button = BI.createWidget({ this.button = BI.createWidget({
type: "bi.icon_button", type: "bi.icon_button",
element: this, element: this,
cls: o.iconClass, cls: o.iconCls,
height: o.height, height: o.height,
iconWidth: o.iconWidth, iconWidth: o.iconWidth,
iconHeight: o.iconHeight, iconHeight: o.iconHeight,
@ -73,9 +73,9 @@ BI.IconChangeButton = BI.inherit(BI.Single, {
setIcon: function (cls) { setIcon: function (cls) {
var o = this.options; var o = this.options;
if (o.iconClass !== cls) { if (o.iconCls !== cls) {
this.element.removeClass(o.iconClass).addClass(cls); this.element.removeClass(o.iconCls).addClass(cls);
o.iconClass = cls; o.iconCls = cls;
} }
} }
}); });

5
src/case/button/item.singleselect.icontext.js

@ -8,8 +8,7 @@ BI.SingleSelectIconTextItem = BI.inherit(BI.Single, {
_defaultConfig: function () { _defaultConfig: function () {
return BI.extend(BI.SingleSelectIconTextItem.superclass._defaultConfig.apply(this, arguments), { return BI.extend(BI.SingleSelectIconTextItem.superclass._defaultConfig.apply(this, arguments), {
extraCls: "bi-single-select-icon-text-item bi-list-item-active", extraCls: "bi-single-select-icon-text-item bi-list-item-active",
iconClass: "", iconCls: "",
hgap: 10,
height: 25 height: 25
}); });
}, },
@ -19,7 +18,7 @@ BI.SingleSelectIconTextItem = BI.inherit(BI.Single, {
this.text = BI.createWidget({ this.text = BI.createWidget({
type: "bi.icon_text_item", type: "bi.icon_text_item",
element: this, element: this,
cls: o.iconClass, cls: o.iconCls,
once: o.once, once: o.once,
selected: o.selected, selected: o.selected,
height: o.height, height: o.height,

4
src/case/combo/iconcombo/combo.icon.js

@ -10,7 +10,7 @@ BI.IconCombo = BI.inherit(BI.Widget, {
baseCls: "bi-icon-combo", baseCls: "bi-icon-combo",
width: 24, width: 24,
height: 24, height: 24,
iconClass: "", iconCls: "",
el: {}, el: {},
popup: {}, popup: {},
minWidth: 100, minWidth: 100,
@ -30,7 +30,7 @@ BI.IconCombo = BI.inherit(BI.Widget, {
var self = this, o = this.options; var self = this, o = this.options;
this.trigger = BI.createWidget(o.el, { this.trigger = BI.createWidget(o.el, {
type: "bi.icon_combo_trigger", type: "bi.icon_combo_trigger",
iconClass: o.iconClass, iconCls: o.iconCls,
title: o.title, title: o.title,
items: o.items, items: o.items,
width: o.width, width: o.width,

14
src/case/combo/iconcombo/trigger.iconcombo.js

@ -10,7 +10,7 @@ BI.IconComboTrigger = BI.inherit(BI.Trigger, {
extraCls: "bi-icon-combo-trigger", extraCls: "bi-icon-combo-trigger",
el: {}, el: {},
items: [], items: [],
iconClass: "", iconCls: "",
width: 25, width: 25,
height: 25, height: 25,
isShowDown: true isShowDown: true
@ -22,7 +22,7 @@ BI.IconComboTrigger = BI.inherit(BI.Trigger, {
var o = this.options, self = this; var o = this.options, self = this;
this.button = BI.createWidget(o.el, { this.button = BI.createWidget(o.el, {
type: "bi.icon_change_button", type: "bi.icon_change_button",
cls: "icon-combo-trigger-icon " + o.iconClass, cls: "icon-combo-trigger-icon " + o.iconCls,
disableSelected: true, disableSelected: true,
width: o.width, width: o.width,
height: o.height, height: o.height,
@ -60,7 +60,7 @@ BI.IconComboTrigger = BI.inherit(BI.Trigger, {
populate: function (items) { populate: function (items) {
var o = this.options; var o = this.options;
this.options.items = items || []; this.options.items = items || [];
this.button.setIcon(o.iconClass); this.button.setIcon(o.iconCls);
this.button.setSelected(false); this.button.setSelected(false);
this.down.setSelected(false); this.down.setSelected(false);
}, },
@ -68,19 +68,19 @@ BI.IconComboTrigger = BI.inherit(BI.Trigger, {
setValue: function (v) { setValue: function (v) {
BI.IconComboTrigger.superclass.setValue.apply(this, arguments); BI.IconComboTrigger.superclass.setValue.apply(this, arguments);
var o = this.options; var o = this.options;
var iconClass = ""; var iconCls = "";
v = BI.isArray(v) ? v[0] : v; v = BI.isArray(v) ? v[0] : v;
if (BI.any(this.options.items, function (i, item) { if (BI.any(this.options.items, function (i, item) {
if (v === item.value) { if (v === item.value) {
iconClass = item.iconClass; iconCls = item.iconCls;
return true; return true;
} }
})) { })) {
this.button.setIcon(iconClass); this.button.setIcon(iconCls);
this.button.setSelected(true); this.button.setSelected(true);
this.down.setSelected(true); this.down.setSelected(true);
} else { } else {
this.button.setIcon(o.iconClass); this.button.setIcon(o.iconCls);
this.button.setSelected(false); this.button.setSelected(false);
this.down.setSelected(false); this.down.setSelected(false);
} }

2
src/case/trigger/trigger.icon.text.js

@ -46,7 +46,7 @@ BI.IconTextTrigger = BI.inherit(BI.Trigger, {
items: [{ items: [{
el: { el: {
type: "bi.icon_change_button", type: "bi.icon_change_button",
cls: "icon-combo-trigger-icon " + o.iconClass, cls: "icon-combo-trigger-icon " + o.iconCls,
ref: function (_ref) { ref: function (_ref) {
self.icon = _ref; self.icon = _ref;
}, },

10
src/case/trigger/trigger.icon.text.select.js

@ -19,7 +19,7 @@ BI.SelectIconTextTrigger = BI.inherit(BI.Trigger, {
type: "bi.icon_text_trigger", type: "bi.icon_text_trigger",
element: this, element: this,
text: obj.text, text: obj.text,
iconClass: obj.iconClass, iconCls: obj.iconCls,
height: o.height height: o.height
}); });
}, },
@ -33,7 +33,7 @@ BI.SelectIconTextTrigger = BI.inherit(BI.Trigger, {
if (BI.deepContains(vals, item.value)) { if (BI.deepContains(vals, item.value)) {
result = { result = {
text: item.text || item.value, text: item.text || item.value,
iconClass: item.iconClass iconCls: item.iconCls
}; };
return true; return true;
} }
@ -42,12 +42,12 @@ BI.SelectIconTextTrigger = BI.inherit(BI.Trigger, {
if (BI.isNotNull(result)) { if (BI.isNotNull(result)) {
return { return {
text: result.text, text: result.text,
iconClass: result.iconClass iconCls: result.iconCls
}; };
} else { } else {
return { return {
text: o.text, text: o.text,
iconClass: "" iconCls: ""
}; };
} }
}, },
@ -55,7 +55,7 @@ BI.SelectIconTextTrigger = BI.inherit(BI.Trigger, {
setValue: function (vals) { setValue: function (vals) {
var obj = this._digist(vals, this.options.items); var obj = this._digist(vals, this.options.items);
this.trigger.setText(obj.text); this.trigger.setText(obj.text);
this.trigger.setIcon(obj.iconClass); this.trigger.setIcon(obj.iconCls);
}, },
populate: function (items) { populate: function (items) {

3
src/widget/downlist/combo.downlist.js

@ -5,8 +5,7 @@ BI.DownListCombo = BI.inherit(BI.Widget, {
_defaultConfig: function () { _defaultConfig: function () {
return BI.extend(BI.DownListCombo.superclass._defaultConfig.apply(this, arguments), { return BI.extend(BI.DownListCombo.superclass._defaultConfig.apply(this, arguments), {
baseCls: "bi-down-list-combo", baseCls: "bi-down-list-combo",
invalid: false, height: 24,
height: 25,
items: [], items: [],
adjustLength: 0, adjustLength: 0,
direction: "bottom", direction: "bottom",

8
src/widget/numberinterval/numberinterval.js

@ -125,12 +125,12 @@ BI.NumberInterval = BI.inherit(BI.Single, {
height: o.height - 2, height: o.height - 2,
items: [{ items: [{
text: "(" + BI.i18nText("BI-Less_Than") + ")", text: "(" + BI.i18nText("BI-Less_Than") + ")",
iconClass: "less-font", iconCls: "less-font",
value: 0 value: 0
}, { }, {
text: "(" + BI.i18nText("BI-Less_And_Equal") + ")", text: "(" + BI.i18nText("BI-Less_And_Equal") + ")",
value: 1, value: 1,
iconClass: "less-equal-font" iconCls: "less-equal-font"
}] }]
}); });
if (o.closemin === true) { if (o.closemin === true) {
@ -144,12 +144,12 @@ BI.NumberInterval = BI.inherit(BI.Single, {
height: o.height - 2, height: o.height - 2,
items: [{ items: [{
text: "(" + BI.i18nText("BI-Less_Than") + ")", text: "(" + BI.i18nText("BI-Less_Than") + ")",
iconClass: "less-font", iconCls: "less-font",
value: 0 value: 0
}, { }, {
text: "(" + BI.i18nText("BI-Less_And_Equal") + ")", text: "(" + BI.i18nText("BI-Less_And_Equal") + ")",
value: 1, value: 1,
iconClass: "less-equal-font" iconCls: "less-equal-font"
}] }]
}); });
if (o.closemax === true) { if (o.closemax === true) {

Loading…
Cancel
Save