Skip to content

Commit

Permalink
FNA_SDL2_FORCE_BASE_PATH->FNA_SDL_FORCE_BASE_PATH
Browse files Browse the repository at this point in the history
  • Loading branch information
flibitijibibo committed Feb 6, 2025
1 parent 3ee5399 commit 696db3f
Show file tree
Hide file tree
Showing 3 changed files with 8 additions and 2 deletions.
6 changes: 6 additions & 0 deletions src/FNAPlatform/FNAPlatform.cs
Original file line number Diff line number Diff line change
Expand Up @@ -100,6 +100,12 @@ static FNAPlatform()
);
}

// Compatibility for old variable names
Environment.SetEnvironmentVariable(
"FNA_SDL_FORCE_BASE_PATH",
Environment.GetEnvironmentVariable("FNA_SDL2_FORCE_BASE_PATH")
);

if (useSDL3)
{
Malloc = SDL3_FNAPlatform.Malloc;
Expand Down
2 changes: 1 addition & 1 deletion src/FNAPlatform/SDL2_FNAPlatform.cs
Original file line number Diff line number Diff line change
Expand Up @@ -1449,7 +1449,7 @@ public static void SetRelativeMouseMode(IntPtr window, bool enable)

private static string GetBaseDirectory()
{
if (Environment.GetEnvironmentVariable("FNA_SDL2_FORCE_BASE_PATH") != "1")
if (Environment.GetEnvironmentVariable("FNA_SDL_FORCE_BASE_PATH") != "1")
{
// If your platform uses a CLR, you want to be in this list!
if ( OSVersion.Equals("Windows") ||
Expand Down
2 changes: 1 addition & 1 deletion src/FNAPlatform/SDL3_FNAPlatform.cs
Original file line number Diff line number Diff line change
Expand Up @@ -1367,7 +1367,7 @@ public static void SetRelativeMouseMode(IntPtr window, bool enable)

private static string GetBaseDirectory()
{
if (Environment.GetEnvironmentVariable("FNA_SDL2_FORCE_BASE_PATH") != "1")
if (Environment.GetEnvironmentVariable("FNA_SDL_FORCE_BASE_PATH") != "1")
{
// If your platform uses a CLR, you want to be in this list!
if ( OSVersion.Equals("Windows") ||
Expand Down

0 comments on commit 696db3f

Please sign in to comment.