From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from firstgate.proxmox.com (firstgate.proxmox.com [212.224.123.68]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits)) (No client certificate requested) by lists.proxmox.com (Postfix) with ESMTPS id AB904AA76 for ; Tue, 5 Apr 2022 14:31:05 +0200 (CEST) Received: from firstgate.proxmox.com (localhost [127.0.0.1]) by firstgate.proxmox.com (Proxmox) with ESMTP id 8627B20B31 for ; Tue, 5 Apr 2022 14:30:35 +0200 (CEST) Received: from proxmox-new.maurer-it.com (proxmox-new.maurer-it.com [94.136.29.106]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits)) (No client certificate requested) by firstgate.proxmox.com (Proxmox) with ESMTPS id 9B0BD20B25 for ; Tue, 5 Apr 2022 14:30:34 +0200 (CEST) Received: from proxmox-new.maurer-it.com (localhost.localdomain [127.0.0.1]) by proxmox-new.maurer-it.com (Proxmox) with ESMTP id 60892459C6 for ; Tue, 5 Apr 2022 14:30:34 +0200 (CEST) From: Aaron Lauterer To: pve-devel@lists.proxmox.com Date: Tue, 5 Apr 2022 14:30:15 +0200 Message-Id: <20220405123016.2911726-5-a.lauterer@proxmox.com> X-Mailer: git-send-email 2.30.2 In-Reply-To: <20220405123016.2911726-1-a.lauterer@proxmox.com> References: <20220405123016.2911726-1-a.lauterer@proxmox.com> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-SPAM-LEVEL: Spam detection results: 0 AWL -1.575 Adjusted score from AWL reputation of From: address BAYES_00 -1.9 Bayes spam probability is 0 to 1% ENA_SUBJ_ODD_CASE 3.2 Subject has odd case KAM_DMARC_STATUS 0.01 Test Rule for DKIM or SPF Failure with Strict Alignment SPF_HELO_NONE 0.001 SPF: HELO does not publish an SPF Record SPF_PASS -0.001 SPF: sender matches SPF record T_SCC_BODY_TEXT_LINE -0.01 - Subject: [pve-devel] [PATCH v6 manager 4/5] ui: BusTypeSelector: change noVirtIO to withVirtIO X-BeenThere: pve-devel@lists.proxmox.com X-Mailman-Version: 2.1.29 Precedence: list List-Id: Proxmox VE development discussion List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 05 Apr 2022 12:31:05 -0000 Double negated properties make it harder than necessary to parse conditions. Signed-off-by: Aaron Lauterer Reviewed-by: Fabian Ebner --- www/manager6/form/BusTypeSelector.js | 4 ++-- www/manager6/form/ControllerSelector.js | 4 ++-- www/manager6/qemu/CDEdit.js | 2 +- www/manager6/qemu/CIDriveEdit.js | 2 +- 4 files changed, 6 insertions(+), 6 deletions(-) diff --git a/www/manager6/form/BusTypeSelector.js b/www/manager6/form/BusTypeSelector.js index a420e56f..0f040229 100644 --- a/www/manager6/form/BusTypeSelector.js +++ b/www/manager6/form/BusTypeSelector.js @@ -2,7 +2,7 @@ Ext.define('PVE.form.BusTypeSelector', { extend: 'Proxmox.form.KVComboBox', alias: 'widget.pveBusSelector', - noVirtIO: false, + withVirtIO: true, withUnused: false, initComponent: function() { @@ -10,7 +10,7 @@ Ext.define('PVE.form.BusTypeSelector', { me.comboItems = [['ide', 'IDE'], ['sata', 'SATA']]; - if (!me.noVirtIO) { + if (me.withVirtIO) { me.comboItems.push(['virtio', 'VirtIO Block']); } diff --git a/www/manager6/form/ControllerSelector.js b/www/manager6/form/ControllerSelector.js index 798dc4b2..d84c49d6 100644 --- a/www/manager6/form/ControllerSelector.js +++ b/www/manager6/form/ControllerSelector.js @@ -2,7 +2,7 @@ Ext.define('PVE.form.ControllerSelector', { extend: 'Ext.form.FieldContainer', alias: 'widget.pveControllerSelector', - noVirtIO: false, + withVirtIO: true, withUnused: false, vmconfig: {}, // used to check for existing devices @@ -73,7 +73,7 @@ Ext.define('PVE.form.ControllerSelector', { name: 'controller', itemId: 'controller', value: PVE.qemu.OSDefaults.generic.busType, - noVirtIO: me.noVirtIO, + withVirtIO: me.withVirtIO, withUnused: me.withUnused, allowBlank: false, flex: 2, diff --git a/www/manager6/qemu/CDEdit.js b/www/manager6/qemu/CDEdit.js index 72c01037..fc7a59cc 100644 --- a/www/manager6/qemu/CDEdit.js +++ b/www/manager6/qemu/CDEdit.js @@ -71,7 +71,7 @@ Ext.define('PVE.qemu.CDInputPanel', { if (!me.confid) { me.bussel = Ext.create('PVE.form.ControllerSelector', { - noVirtIO: true, + withVirtIO: false, }); items.push(me.bussel); } diff --git a/www/manager6/qemu/CIDriveEdit.js b/www/manager6/qemu/CIDriveEdit.js index 754b8353..a9ca8bf1 100644 --- a/www/manager6/qemu/CIDriveEdit.js +++ b/www/manager6/qemu/CIDriveEdit.js @@ -36,7 +36,7 @@ Ext.define('PVE.qemu.CIDriveInputPanel', { me.items = [ { xtype: 'pveControllerSelector', - noVirtIO: true, + withVirtIO: false, itemId: 'drive', fieldLabel: gettext('CloudInit Drive'), name: 'drive', -- 2.30.2