From e3cc4eda3b0f037288bdc982b8ebf63e53d51a2c Mon Sep 17 00:00:00 2001 From: ZeldaZach Date: Fri, 10 Jan 2025 22:19:46 -0500 Subject: [PATCH] Fix SoundEngine on Mac --- cockatrice/src/client/sound_engine.cpp | 17 ++++++++--------- 1 file changed, 8 insertions(+), 9 deletions(-) diff --git a/cockatrice/src/client/sound_engine.cpp b/cockatrice/src/client/sound_engine.cpp index 79bfc6dc2..849088704 100644 --- a/cockatrice/src/client/sound_engine.cpp +++ b/cockatrice/src/client/sound_engine.cpp @@ -110,15 +110,14 @@ QStringMap &SoundEngine::getAvailableThemes() } // load themes from cockatrice system dir -// dir.setPath(qApp->applicationDirPath() + -//#ifdef Q_OS_MAC -// "/../Resources/sounds" -//#elif defined(Q_OS_WIN) -// "/sounds" -//#else // linux -// "/../share/cockatrice/sounds" -//#endif - dir.setPath("/Applications/Cockatrice.app/Contents/Resources/sounds" + dir.setPath(qApp->applicationDirPath() + +#ifdef Q_OS_MAC + "/../Resources/sounds" +#elif defined(Q_OS_WIN) + "/sounds" +#else // linux + "/../share/cockatrice/sounds" +#endif ); for (const QString &themeName : dir.entryList(QDir::AllDirs | QDir::NoDotAndDotDot, QDir::Name)) {