From dc88cacc3533b122085c34fada2588637252fdf5 Mon Sep 17 00:00:00 2001 From: matellush <202132988+matellush@users.noreply.github.com> Date: Thu, 3 Apr 2025 22:36:02 +0200 Subject: [PATCH] fix: Add `QT_QPA_PLATFORM` environment variable --- .../Services/Launcher/Helpers/DolphinLaunchHelper.cs | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/WheelWizard/Services/Launcher/Helpers/DolphinLaunchHelper.cs b/WheelWizard/Services/Launcher/Helpers/DolphinLaunchHelper.cs index bb37fbe1..687aa598 100644 --- a/WheelWizard/Services/Launcher/Helpers/DolphinLaunchHelper.cs +++ b/WheelWizard/Services/Launcher/Helpers/DolphinLaunchHelper.cs @@ -125,10 +125,12 @@ public static void LaunchDolphin(string arguments = "", bool shellExecute = fals startInfo.ArgumentList.Add("sh"); startInfo.ArgumentList.Add("-c"); startInfo.ArgumentList.Add("--"); - if (RuntimeInformation.IsOSPlatform(OSPlatform.Linux) && - PathManager.IsFlatpakDolphinFilePath()) + if (RuntimeInformation.IsOSPlatform(OSPlatform.Linux)) { - dolphinLocation = FixFlatpakDolphinPermissions(dolphinLocation); + if (PathManager.IsFlatpakDolphinFilePath()) + dolphinLocation = FixFlatpakDolphinPermissions(dolphinLocation); + else + startInfo.EnvironmentVariables["QT_QPA_PLATFORM"] = "xcb"; } startInfo.ArgumentList.Add($"{dolphinLocation} {dolphinLaunchArguments}"); startInfo.UseShellExecute = false;