diff options
author | Jan200101 <sentrycraft123@gmail.com> | 2022-12-11 11:01:33 +0100 |
---|---|---|
committer | Jan200101 <sentrycraft123@gmail.com> | 2022-12-11 11:01:33 +0100 |
commit | 2c1e887c8d7331df6d93dadea7355c019da4185a (patch) | |
tree | 0895bae377b379b988cbb5f033f2d6aa167698a1 /launcher/Application.cpp | |
parent | 514e7ae6a00811a0ee1f20dfc856f69404fd883c (diff) | |
download | PrismLauncher-2c1e887c8d7331df6d93dadea7355c019da4185a.tar.gz PrismLauncher-2c1e887c8d7331df6d93dadea7355c019da4185a.tar.bz2 PrismLauncher-2c1e887c8d7331df6d93dadea7355c019da4185a.zip |
chore: replace naive mangohud detection with vulkan layer detection
Signed-off-by: Jan200101 <sentrycraft123@gmail.com>
Diffstat (limited to 'launcher/Application.cpp')
-rw-r--r-- | launcher/Application.cpp | 14 |
1 files changed, 3 insertions, 11 deletions
diff --git a/launcher/Application.cpp b/launcher/Application.cpp index 4ba9eb9b..8447083c 100644 --- a/launcher/Application.cpp +++ b/launcher/Application.cpp @@ -125,6 +125,7 @@ #ifdef Q_OS_LINUX #include <dlfcn.h> #include "gamemode_client.h" +#include "MangoHud.h" #endif @@ -1519,17 +1520,8 @@ void Application::updateCapabilities() if (gamemode_query_status() >= 0) m_capabilities |= SupportsGameMode; - { - void *dummy = dlopen("libMangoHud_dlsym.so", RTLD_LAZY); - // try normal variant as well - if (dummy == NULL) - dummy = dlopen("libMangoHud.so", RTLD_LAZY); - - if (dummy != NULL) { - dlclose(dummy); - m_capabilities |= SupportsMangoHud; - } - } + if (!MangoHud::getLibraryString().isEmpty()) + m_capabilities |= SupportsMangoHud; #endif } |