From 3c2f8b65ce893dc2120e079e3e2a787c435cce3f Mon Sep 17 00:00:00 2001 From: Ilya Fedin Date: Thu, 27 Mar 2025 15:00:30 +0000 Subject: [PATCH] Let QIcon::fromTheme check whether the tray icon is valid QIcon::fromTheme overload with a fallback does a smarter check whether the icon is valid, use it to prevent getting a half-valid QIcon. --- Telegram/SourceFiles/platform/linux/tray_linux.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Telegram/SourceFiles/platform/linux/tray_linux.cpp b/Telegram/SourceFiles/platform/linux/tray_linux.cpp index 37ef31e259..9e7949c08a 100644 --- a/Telegram/SourceFiles/platform/linux/tray_linux.cpp +++ b/Telegram/SourceFiles/platform/linux/tray_linux.cpp @@ -95,7 +95,7 @@ QIcon IconGraphic::systemIcon() const { if (candidate.isEmpty()) { continue; } - const auto icon = QIcon::fromTheme(candidate); + const auto icon = QIcon::fromTheme(candidate, QIcon()); if (icon.name() == candidate) { return icon; }