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 272C4B765 for ; Fri, 29 Apr 2022 18:50:25 +0200 (CEST) Received: from firstgate.proxmox.com (localhost [127.0.0.1]) by firstgate.proxmox.com (Proxmox) with ESMTP id 0F841CED2 for ; Fri, 29 Apr 2022 18:50:25 +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 2AB68CEBB for ; Fri, 29 Apr 2022 18:50:23 +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 F3A744303B for ; Fri, 29 Apr 2022 18:50:22 +0200 (CEST) From: Stoiko Ivanov To: pve-devel@lists.proxmox.com Date: Fri, 29 Apr 2022 18:50:08 +0200 Message-Id: <20220429165008.734273-3-s.ivanov@proxmox.com> X-Mailer: git-send-email 2.30.2 In-Reply-To: <20220429165008.734273-1-s.ivanov@proxmox.com> References: <20220429165008.734273-1-s.ivanov@proxmox.com> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-SPAM-LEVEL: Spam detection results: 0 AWL 0.201 Adjusted score from AWL reputation of From: address BAYES_00 -1.9 Bayes spam probability is 0 to 1% 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 Subject: [pve-devel] [PATCH manager 1/1] ui: qemu: show hint about prerequisites for virgl display 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: Fri, 29 Apr 2022 16:50:25 -0000 since there is no hard dependency on the needed libraries (and we cannot easily check if a fitting GPU is present in the GUI) - notify the user about the prerequisites - else the error-messages might be a bit confusing [0] Suggested-by: Thomas Lamprecht Signed-off-by: Stoiko Ivanov [0] https://forum.proxmox.com/threads/.61801/post-466750 Signed-off-by: Stoiko Ivanov --- www/manager6/qemu/DisplayEdit.js | 15 +++++++++++++++ 1 file changed, 15 insertions(+) diff --git a/www/manager6/qemu/DisplayEdit.js b/www/manager6/qemu/DisplayEdit.js index 9bb1763e..602729d6 100644 --- a/www/manager6/qemu/DisplayEdit.js +++ b/www/manager6/qemu/DisplayEdit.js @@ -49,6 +49,13 @@ Ext.define('PVE.qemu.DisplayInputPanel', { memoryfield.setEmptyText(Proxmox.Utils.defaultText); } memoryfield.setDisabled(disableMemoryField); + + let hintfield = this.up('panel').down('field[name=virglhint]'); + if (val === 'virtio-gl') { + hintfield.setHidden(false); + } else { + hintfield.setHidden(true); + } }, }, }, @@ -60,6 +67,14 @@ Ext.define('PVE.qemu.DisplayInputPanel', { maxValue: 512, step: 4, name: 'memory', + }, + { + xtype: 'displayfield', + userCls: 'pmx-hint', + hidden: true, + name: 'virglhint', + value: gettext('Note: You need to have a physical GPU in the host and have the necessary ' + + 'driver and library packages (libgl1, libegl1) installed'), }], }); -- 2.30.2