diff options
author | saturneric <[email protected]> | 2025-05-01 00:23:24 +0000 |
---|---|---|
committer | saturneric <[email protected]> | 2025-05-01 00:23:24 +0000 |
commit | cd8124507237dda9066890748b7e0fbe59e7722d (patch) | |
tree | 0d2d5ca5b851fb7837fbb206320953d67e448db4 /src/core/function/GlobalSettingStation.cpp | |
parent | fix: install and packaging on linux (diff) | |
download | GpgFrontend-cd8124507237dda9066890748b7e0fbe59e7722d.tar.gz GpgFrontend-cd8124507237dda9066890748b7e0fbe59e7722d.zip |
fix: should only use fusion as default style under app image env
Diffstat (limited to 'src/core/function/GlobalSettingStation.cpp')
-rw-r--r-- | src/core/function/GlobalSettingStation.cpp | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/src/core/function/GlobalSettingStation.cpp b/src/core/function/GlobalSettingStation.cpp index 20bbfc55..7632f7dc 100644 --- a/src/core/function/GlobalSettingStation.cpp +++ b/src/core/function/GlobalSettingStation.cpp @@ -32,6 +32,7 @@ // #include "core/module/ModuleManager.h" +#include "core/utils/CommonUtils.h" #include "core/utils/FilesystemUtils.h" namespace GpgFrontend { @@ -52,7 +53,7 @@ class GlobalSettingStation::Impl { LOG_I() << "GpgFrontend runs in the portable mode now"; #if defined(__linux__) - if (!qEnvironmentVariable("APPIMAGE").isEmpty()) { + if (IsAppImageENV()) { LOG_I() << "app image path: " << qEnvironmentVariable("APPIMAGE"); QFileInfo info( QString::fromUtf8(qEnvironmentVariable("APPIMAGE").toUtf8())); @@ -159,11 +160,11 @@ class GlobalSettingStation::Impl { #if defined(__linux__) // AppImage - if (!qEnvironmentVariable("APPIMAGE").isEmpty()) { + if (IsAppImageENV()) { return qEnvironmentVariable("APPDIR") + "/usr/lib/modules"; } // Flatpak - if (!qEnvironmentVariable("container").isEmpty()) { + if (IsFlatpakENV()) { return "/app/lib/gpgfrontend/modules"; } #endif |