diff --git a/src/form/field/ComboBox.mjs b/src/form/field/ComboBox.mjs index a5a9c94ab..b3912ec2d 100644 --- a/src/form/field/ComboBox.mjs +++ b/src/form/field/ComboBox.mjs @@ -392,7 +392,7 @@ class ComboBox extends Picker { // Filter resulting in something to show if (store.getCount()) { - me.getPicker().hidden = false; + me.showPicker(); // List might not exist until the picker is created const @@ -620,19 +620,6 @@ class ComboBox extends Picker { this.update() } - /** - * - */ - onPickerTriggerClick() { - let me = this; - - if (me.picker?.isVisible) { - me.picker.hidden = true - } else if (!me.disabled && !me.readOnly) { - me.doFilter(null) - } - } - /** * Selecting a record, if required * @param {Object[]} items @@ -679,6 +666,20 @@ class ComboBox extends Picker { me.list.selectItem(index) } + /** + * @override + */ + togglePicker() { + let me = this, + {picker} = me; + + if (picker?.hidden === false) { + picker.hidden = true + } else if (!me.disabled && !me.readOnly) { + me.doFilter(null) + } + } + /** * Override this method as needed inside class extensions. * @param {*} value diff --git a/src/form/field/Picker.mjs b/src/form/field/Picker.mjs index e7113d2e6..d80ede52d 100644 --- a/src/form/field/Picker.mjs +++ b/src/form/field/Picker.mjs @@ -288,8 +288,8 @@ class Picker extends Text { // We processed this event, and it should not proceed to ancestor components data.cancelBubble = true; - // And no further listeers should be notified - return false; + // And no further listeners should be notified + return false } }