1
0
mirror of https://github.com/ppy/osu.git synced 2024-12-14 07:42:57 +08:00

Associate on startup

This commit is contained in:
Susko3 2024-02-03 17:04:06 +01:00
parent 498d93be61
commit 03578821c0
2 changed files with 7 additions and 1 deletions

View File

@ -134,9 +134,14 @@ namespace osu.Desktop
LoadComponentAsync(new DiscordRichPresence(), Add);
if (RuntimeInfo.OS == RuntimeInfo.Platform.Windows)
if (RuntimeInfo.OS == RuntimeInfo.Platform.Windows && OperatingSystem.IsWindows())
{
LoadComponentAsync(new GameplayWinKeyBlocker(), Add);
string? executableLocation = Path.GetDirectoryName(typeof(OsuGameDesktop).Assembly.Location);
LoadComponentAsync(new WindowsAssociationManager(Path.Join(executableLocation, @"osu!.exe"), "osu"), Add);
}
LoadComponentAsync(new ElevatedPrivilegesChecker(), Add);
osuSchemeLinkIPCChannel = new OsuSchemeLinkIPCChannel(Host, this);

View File

@ -69,6 +69,7 @@ namespace osu.Game.Updater
private void load()
{
localisationParameters = localisation.CurrentParameters.GetBoundCopy();
InstallAssociations();
}
protected override void LoadComplete()