Merge pull request #8769 from ChillerDragon/pr_delete_skins7_hotkey

Add delete hotkey for 0.7 skins
This commit is contained in:
Robert Müller 2024-08-19 05:12:48 +00:00 committed by GitHub
commit 288f999e9d
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -248,7 +248,7 @@ void CMenus::RenderSettingsTee7(CUIRect MainView)
else if(m_pSelectedSkin && (m_pSelectedSkin->m_Flags & CSkins7::SKINFLAG_STANDARD) == 0)
{
static CButtonContainer s_CustomSkinDeleteButton;
if(DoButton_Menu(&s_CustomSkinDeleteButton, Localize("Delete"), 0, &ButtonMiddle))
if(DoButton_Menu(&s_CustomSkinDeleteButton, Localize("Delete"), 0, &ButtonMiddle) || Ui()->ConsumeHotkey(CUi::HOTKEY_DELETE))
{
char aBuf[128];
str_format(aBuf, sizeof(aBuf), Localize("Are you sure that you want to delete the skin '%s'?"), m_pSelectedSkin->m_aName);