guy 2 years ago
parent
commit
802d984576
  1. 2
      src/case/trigger/trigger.editor.js
  2. 20
      src/case/trigger/trigger.icon.text.js
  3. 5
      src/case/trigger/trigger.text.js
  4. 2
      src/case/trigger/trigger.text.small.js
  5. 2
      src/widget/textvaluedownlistcombo/combo.textvaluedownlist.js

2
src/case/trigger/trigger.editor.js

@ -67,7 +67,7 @@ BI.EditorTrigger = BI.inherit(BI.Trigger, {
type: "bi.trigger_icon_button",
width: o.triggerWidth || BI.pixFormat(o.height, 2)
},
width: o.triggerWidth || BI.pixFormat(o.height, 2)
width: ""
}
]
});

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

@ -42,7 +42,7 @@ BI.IconTextTrigger = BI.inherit(BI.Trigger, {
BI.createWidget({
element: this,
type: "bi.horizontal_fill",
columnSize: [BI.isEmptyString(o.iconCls) ? 0 : (o.iconWrapperWidth || o.height), "fill", o.triggerWidth || o.height],
columnSize: ["", "fill", ""],
ref: function (_ref) {
self.wrapper = _ref;
},
@ -50,7 +50,9 @@ BI.IconTextTrigger = BI.inherit(BI.Trigger, {
el: {
type: "bi.icon_change_button",
cls: "icon-combo-trigger-icon",
width: o.triggerWidth || o.height,
iconCls: o.iconCls,
invisible: !o.iconCls,
ref: function (_ref) {
self.icon = _ref;
},
@ -74,21 +76,7 @@ BI.IconTextTrigger = BI.inherit(BI.Trigger, {
setIcon: function (iconCls) {
var o = this.options;
this.icon.setIcon(iconCls);
var iconItem = this.wrapper.attr("items")[0];
var textItem = this.wrapper.attr("items")[1];
if (BI.isNull(iconCls) || BI.isEmptyString(iconCls)) {
if (iconItem.width !== 0) {
iconItem.width = 0;
textItem.lgap = 5;
this.wrapper.resize();
}
} else {
if (iconItem.width !== (o.iconWrapperWidth || o.height)) {
iconItem.width = (o.iconWrapperWidth || o.height);
textItem.lgap = 0;
this.wrapper.resize();
}
}
this.icon.setVisible(!!iconCls);
},
setTextCls: function (cls) {

5
src/case/trigger/trigger.text.js

@ -60,7 +60,7 @@ BI.TextTrigger = BI.inherit(BI.Trigger, {
return ({
type: "bi.horizontal_fill",
columnSize: ["fill", o.triggerWidth || o.height],
columnSize: ["fill", ""],
items: [
{
el: label,
@ -68,6 +68,8 @@ BI.TextTrigger = BI.inherit(BI.Trigger, {
}, {
el: o.allowClear ? {
type: "bi.vertical_adapt",
width: o.triggerWidth || o.height,
height: o.height,
horizontalAlign: "left",
scrollable: false,
items: [
@ -80,7 +82,6 @@ BI.TextTrigger = BI.inherit(BI.Trigger, {
cls: "close-h-font " + (o.allowClear ? "clear-button" : ""),
stopPropagation: true,
width: o.triggerWidth || o.height,
height: o.height,
invisible: !BI.isNotEmptyString(o.text),
handler: function () {
self.fireEvent(BI.TextTrigger.EVENT_CLEAR);

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

@ -43,7 +43,7 @@ BI.SmallTextTrigger = BI.inherit(BI.Trigger, {
width: "fill"
}, {
el: this.trigerButton,
width: o.triggerWidth || o.height
width: ""
}
]
});

2
src/widget/textvaluedownlistcombo/combo.textvaluedownlist.js

@ -5,7 +5,7 @@
BI.TextValueDownListCombo = BI.inherit(BI.Widget, {
_defaultConfig: function (config) {
return BI.extend(BI.TextValueDownListCombo.superclass._defaultConfig.apply(this, arguments), {
baseCls: "bi-text-value-down-list-combo " + (config.simple ? "bi-border-bottom" : "bi-border"),
baseCls: "bi-text-value-down-list-combo bi-border-radius " + (config.simple ? "bi-border-bottom" : "bi-border"),
height: 24,
});
},

Loading…
Cancel
Save