[pve-devel] [PATCH manager 1/3] Use camel case for InputPanels aliases

Dominik Csapak d.csapak at proxmox.com
Mon Jul 10 11:09:06 CEST 2017


On 07/06/2017 02:09 PM, Emmanuel Kasper wrote:
> Camel Case names for component alias follow Ext recommended practises
> and are used otherwise everyelse in the code base.
>
> No functionnal changes, aliases for these components were not used
> anyway.
> ---
>  www/manager6/qemu/CDEdit.js      | 2 +-
>  www/manager6/qemu/HDEdit.js      | 2 +-
>  www/manager6/qemu/NetworkEdit.js | 2 +-
>  3 files changed, 3 insertions(+), 3 deletions(-)
>
> diff --git a/www/manager6/qemu/CDEdit.js b/www/manager6/qemu/CDEdit.js
> index 1fd36774..51921b8d 100644
> --- a/www/manager6/qemu/CDEdit.js
> +++ b/www/manager6/qemu/CDEdit.js
> @@ -1,6 +1,6 @@
>  Ext.define('PVE.qemu.CDInputPanel', {
>      extend: 'PVE.panel.InputPanel',
> -    alias: 'widget.PVE.qemu.CDInputPanel',
> +    alias: 'widget.pveQemuCDInputPanel',
>
>      insideWizard: false,
>
> diff --git a/www/manager6/qemu/HDEdit.js b/www/manager6/qemu/HDEdit.js
> index 43e5d965..8f5c9dbe 100644
> --- a/www/manager6/qemu/HDEdit.js
> +++ b/www/manager6/qemu/HDEdit.js
> @@ -2,7 +2,7 @@
>  /* 'change' property is assigned a string and then a function */
>  Ext.define('PVE.qemu.HDInputPanel', {
>      extend: 'PVE.panel.InputPanel',
> -    alias: 'widget.PVE.qemu.HDInputPanel',
> +    alias: 'widget.pveQemuHDInputPanel',
>      onlineHelp: 'qm_hard_disk',
>
>      insideWizard: false,
> diff --git a/www/manager6/qemu/NetworkEdit.js b/www/manager6/qemu/NetworkEdit.js
> index b63f5ff0..7e994823 100644
> --- a/www/manager6/qemu/NetworkEdit.js
> +++ b/www/manager6/qemu/NetworkEdit.js
> @@ -1,6 +1,6 @@
>  Ext.define('PVE.qemu.NetworkInputPanel', {
>      extend: 'PVE.panel.InputPanel',
> -    alias: 'widget.PVE.qemu.NetworkInputPanel',
> +    alias: 'widget.pveQemuNetworkInputPanel',
>      onlineHelp: 'qm_network_device',
>
>      insideWizard: false,
>


while we already touching those lines, we could adapt the 'new' style of 
extjs:

instead of:

alias: 'widget.blalba'

we could use:

xtype: 'blabla'

which is shorter and one can directly see what property we set




More information about the pve-devel mailing list