Browse Source

CHART-22056 fix:点击就传值,无需判断是否改变

es6
Tangjinxia 3 years ago
parent
commit
5a2f8c9fb9
  1. 6
      src/case/colorchooser/colorpicker/editor.colorpicker.hex.js

6
src/case/colorchooser/colorpicker/editor.colorpicker.hex.js

@ -72,9 +72,8 @@ BI.HexColorPickerEditor = BI.inherit(BI.Widget, {
listeners: [{ listeners: [{
eventName: BI.ColorChooserShowButton.EVENT_CHANGE, eventName: BI.ColorChooserShowButton.EVENT_CHANGE,
action: function () { action: function () {
var value = self.getValue();
self.setValue("transparent"); self.setValue("transparent");
(value !== "transparent") && self.fireEvent(BI.ColorPickerEditor.EVENT_CHANGE); self.fireEvent(BI.ColorPickerEditor.EVENT_CHANGE);
} }
}], }],
ref: function (_ref) { ref: function (_ref) {
@ -90,9 +89,8 @@ BI.HexColorPickerEditor = BI.inherit(BI.Widget, {
listeners: [{ listeners: [{
eventName: BI.ColorChooserShowButton.EVENT_CHANGE, eventName: BI.ColorChooserShowButton.EVENT_CHANGE,
action: function () { action: function () {
var value = self.getValue();
self.setValue(""); self.setValue("");
(value !== "") && self.fireEvent(BI.ColorPickerEditor.EVENT_CHANGE); self.fireEvent(BI.ColorPickerEditor.EVENT_CHANGE);
} }
}], }],
ref: function (_ref) { ref: function (_ref) {

Loading…
Cancel
Save