[pve-devel] RFC: use declarative style in ExtJS components

Dietmar Maurer dietmar at proxmox.com
Thu Nov 19 17:35:12 CET 2015


> Actually the point I want to make was rather about:
> 
> Ext.define('PVE.form.VNCKeyboardSelector', {
>     extend: 'PVE.form.KVComboBox',
>     alias: ['widget.VNCKeyboardSelector'],
> 
>     initComponent: function() {
> 	var me = this;
> 	me.data = PVE.Utils.kvm_keymap_array();
> 	me.callParent();
>     }
> });
> 
> vs
> 
> Ext.define('PVE.form.VNCKeyboardSelector', {
>     extend: 'PVE.form.KVComboBox',
>     alias: ['widget.VNCKeyboardSelector'],
>     data: PVE.Utils.kvm_keymap_array()
> });

Yes, this makes sense. 
But the previous patch does not make sense to me.




More information about the pve-devel mailing list