From 92ef64d74d287df1b1c81e9795c1e7d45e19c8f6 Mon Sep 17 00:00:00 2001 From: shenleban tongying Date: Fri, 6 Sep 2024 19:18:25 -0400 Subject: [PATCH] feat: allow changing icon on macOS by stop overriding icon set by Info.plist --- src/main.cc | 3 +++ 1 file changed, 3 insertions(+) diff --git a/src/main.cc b/src/main.cc index 7415bc830..94e4aac28 100644 --- a/src/main.cc +++ b/src/main.cc @@ -370,7 +370,10 @@ int main( int argc, char ** argv ) QHotkeyApplication::setApplicationName( "GoldenDict-ng" ); QHotkeyApplication::setOrganizationDomain( "https://github.com/xiaoyifang/goldendict-ng" ); +#ifndef Q_OS_MACOS + // macOS icon is defined in Info.plist QHotkeyApplication::setWindowIcon( QIcon( ":/icons/programicon.png" ) ); +#endif #ifdef Q_OS_WIN // TODO: Force fusion because Qt6.7's "ModernStyle"'s dark theme have problems, need to test / reconsider in future