From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from firstgate.proxmox.com (firstgate.proxmox.com [212.224.123.68]) by lore.proxmox.com (Postfix) with ESMTPS id B844E1FF15E for ; Mon, 10 Nov 2025 12:40:18 +0100 (CET) Received: from firstgate.proxmox.com (localhost [127.0.0.1]) by firstgate.proxmox.com (Proxmox) with ESMTP id 5EB341381B; Mon, 10 Nov 2025 12:41:01 +0100 (CET) From: Markus Frank To: pve-devel@lists.proxmox.com Date: Mon, 10 Nov 2025 12:25:28 +0100 Message-ID: <20251110114032.125526-3-m.frank@proxmox.com> X-Mailer: git-send-email 2.47.3 In-Reply-To: <20251110114032.125526-1-m.frank@proxmox.com> References: <20251110114032.125526-1-m.frank@proxmox.com> MIME-Version: 1.0 X-Bm-Milter-Handled: 55990f41-d878-4baa-be0a-ee34c49e34d2 X-Bm-Transport-Timestamp: 1762774835502 X-SPAM-LEVEL: Spam detection results: 0 AWL 0.001 Adjusted score from AWL reputation of From: address BAYES_00 -1.9 Bayes spam probability is 0 to 1% DMARC_MISSING 0.1 Missing DMARC policy KAM_DMARC_STATUS 0.01 Test Rule for DKIM or SPF Failure with Strict Alignment RCVD_IN_VALIDITY_CERTIFIED_BLOCKED 0.001 ADMINISTRATOR NOTICE: The query to Validity was blocked. See https://knowledge.validity.com/hc/en-us/articles/20961730681243 for more information. RCVD_IN_VALIDITY_RPBL_BLOCKED 0.001 ADMINISTRATOR NOTICE: The query to Validity was blocked. See https://knowledge.validity.com/hc/en-us/articles/20961730681243 for more information. RCVD_IN_VALIDITY_SAFE_BLOCKED 0.001 ADMINISTRATOR NOTICE: The query to Validity was blocked. See https://knowledge.validity.com/hc/en-us/articles/20961730681243 for more information. SPF_HELO_NONE 0.001 SPF: HELO does not publish an SPF Record SPF_PASS -0.001 SPF: sender matches SPF record Subject: [pve-devel] [PATCH pve-manager v1 2/2] ui: qemu: add Vulkan option in DisplayEdit 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: , Reply-To: Proxmox VE development discussion Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Errors-To: pve-devel-bounces@lists.proxmox.com Sender: "pve-devel" The 'isVirgl' formula deactivates the Vulkan option if the type is not 'virtio-gl'. However, it does not reset the option to its default. Therefore, also add a listener function to reset the Vulkan option. Signed-off-by: Markus Frank --- www/manager6/qemu/DisplayEdit.js | 42 +++++++++++++++++++++++++++++++- 1 file changed, 41 insertions(+), 1 deletion(-) diff --git a/www/manager6/qemu/DisplayEdit.js b/www/manager6/qemu/DisplayEdit.js index a2c28ba7..c9a404c4 100644 --- a/www/manager6/qemu/DisplayEdit.js +++ b/www/manager6/qemu/DisplayEdit.js @@ -11,12 +11,30 @@ Ext.define('PVE.qemu.DisplayInputPanel', { return { vga: ret }; }, + controller: { + xclass: 'Ext.app.ViewController', + + onTypeChange: function (type) { + let me = this; + let vm = me.getViewModel(); + + if (type.getValue() !== 'virtio-gl') { + vm.set('vulkan', '__default__'); + vm.notify(); + } + }, + }, + viewModel: { data: { type: '__default__', clipboard: '__default__', + vulkan: '__default__', }, formulas: { + isVirgl: function (get) { + return get('type') === 'virtio-gl'; + }, matchNonGUIOption: function (get) { return get('type').match(/^(serial\d|none)$/); }, @@ -58,10 +76,32 @@ Ext.define('PVE.qemu.DisplayInputPanel', { } return true; }, + listeners: { change: 'onTypeChange' }, bind: { value: '{type}', }, }, + { + xtype: 'proxmoxKVComboBox', + name: 'vulkan', + deleteEmpty: false, + fieldLabel: gettext('Vulkan'), + comboItems: [ + [ + '__default__', + Proxmox.Utils.defaultText + ' (' + Proxmox.Utils.disabledText + ')', + ], + ['venus-512', 'Venus (512 MiB memory window)'], + ['venus-1024', 'Venus (1024 MiB memory window)'], + ['venus-2048', 'Venus (2048 MiB memory window)'], + ['venus-4096', 'Venus (4096 MiB memory window)'], + ['venus-8192', 'Venus (8192 MiB memory window)'], + ], + bind: { + value: '{vulkan}', + disabled: '{!isVirgl}', + }, + }, { xtype: 'proxmoxintegerfield', emptyText: Proxmox.Utils.defaultText, @@ -139,7 +179,7 @@ Ext.define('PVE.qemu.DisplayEdit', { vmconfig: undefined, subject: gettext('Display'), - width: 350, + width: 370, items: [ { -- 2.47.3 _______________________________________________ pve-devel mailing list pve-devel@lists.proxmox.com https://lists.proxmox.com/cgi-bin/mailman/listinfo/pve-devel