1
0
mirror of https://github.com/ppy/osu.git synced 2024-11-11 10:33:30 +08:00

Use cleaner way to specify .exe path

This commit is contained in:
Susko3 2024-02-05 13:12:03 +01:00
parent cdcf5bddda
commit 2f4211249e

View File

@ -138,10 +138,7 @@ namespace osu.Desktop
LoadComponentAsync(new GameplayWinKeyBlocker(), Add);
if (OperatingSystem.IsWindows() && IsDeployedBuild)
{
string? executableLocation = Path.GetDirectoryName(typeof(OsuGameDesktop).Assembly.Location);
LoadComponentAsync(new WindowsAssociationManager(Path.Join(executableLocation, @"osu!.exe"), "osu"), Add);
}
LoadComponentAsync(new WindowsAssociationManager(Path.ChangeExtension(typeof(OsuGameDesktop).Assembly.Location, ".exe"), "osu"), Add);
LoadComponentAsync(new ElevatedPrivilegesChecker(), Add);