Skip to content

Commit 2ea4800

Browse files
committed
Steam infra
Signed-off-by: Isaac Marovitz <[email protected]>
1 parent 32028d8 commit 2ea4800

File tree

1 file changed

+14
-1
lines changed

1 file changed

+14
-1
lines changed

Source/Libraries/HedgeModManager.Steam/SteamLocator.cs

Lines changed: 14 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -32,6 +32,13 @@ public class SteamLocator : IGameLocator
3232
return null;
3333
}
3434

35+
[SupportedOSPlatform("macos")]
36+
private string? FindSteamLibraryMacOS()
37+
{
38+
// TODO: Open a folder selection window
39+
return "";
40+
}
41+
3542
private string? FindSteamLibraryUnix()
3643
{
3744
var pathList = new[]
@@ -62,6 +69,12 @@ public class SteamLocator : IGameLocator
6269
return SteamInstallPath;
6370
}
6471

72+
if (OperatingSystem.IsMacOS())
73+
{
74+
SteamInstallPath = FindSteamLibraryMacOS();
75+
return SteamInstallPath;
76+
}
77+
6578
SteamInstallPath = FindSteamLibraryUnix();
6679
return SteamInstallPath;
6780
}
@@ -128,7 +141,7 @@ public List<SteamGame> Locate()
128141
continue;
129142
}
130143

131-
// Paths will be encoded by Windows steam and will need to be adapted for macOS Paths.
144+
// Paths will be encoded by Windows Steam and will need to be adapted for macOS paths.
132145
// C:\ is equivalent to the Wine prefix.
133146
// Any other drive letter should be removed and treated as raw Unix path.
134147
if (OperatingSystem.IsMacOS())

0 commit comments

Comments
 (0)