mirror of
https://git.proxmox.com/git/pve-manager
synced 2025-08-15 13:36:37 +00:00
ComboGrid.js: allow to select empty value
This commit is contained in:
parent
badcb8d162
commit
8f630c2984
@ -13,6 +13,20 @@ Ext.define('PVE.form.ComboGrid', {
|
||||
return (count > 10) ? 10*lh : 26+count*lh;
|
||||
},
|
||||
|
||||
// hack: allow to select empty value
|
||||
// seems extjs does not allow that when 'editable == false'
|
||||
onKeyUp: function(e, t) {
|
||||
var me = this;
|
||||
var key = e.getKey();
|
||||
|
||||
if (!me.editable && me.allowBlank && !me.multiSelect &&
|
||||
(key == e.BACKSPACE || key == e.DELETE)) {
|
||||
me.setValue('');
|
||||
}
|
||||
|
||||
me.callParent(arguments);
|
||||
},
|
||||
|
||||
// copied from ComboBox
|
||||
createPicker: function() {
|
||||
var me = this,
|
||||
|
Loading…
Reference in New Issue
Block a user