Skip to content

Commit

Permalink
Only show windowed setup menu on Linux
Browse files Browse the repository at this point in the history
  • Loading branch information
drojf committed Oct 12, 2022
1 parent dc72f91 commit dbeb177
Showing 1 changed file with 10 additions and 1 deletion.
11 changes: 10 additions & 1 deletion MOD.Scripts.Core/MODWindowManager.cs
Original file line number Diff line number Diff line change
Expand Up @@ -212,7 +212,16 @@ public static void GameSystemInitSetResolution()
{
PrintPlayerPrefs("On Startup");

if (PlayerPrefsNeedsReset())
// On OS other than Linux, default to disabling fullscreen lock rather than asking the user,
// as it doesn't help with any known bugs on Windows/MacOS
if (Application.platform != RuntimePlatform.LinuxPlayer && !FullscreenLockConfigured())
{
SetFullScreenLock(false);
}

// If crash detected on linux, force fullscreen mode, in case crash was caused by gnome windowed mode bug.
// Also, show the window setup menu again so user can configure fullscreen lock.
if (Application.platform == RuntimePlatform.LinuxPlayer && PlayerPrefsNeedsReset())
{
ForceUnconfigureFullscreenLock();
// TODO: could fully reset playerprefs by calling PlayerPrefs.DeleteAll(), but not sure if such drastic measures are necessary?
Expand Down

0 comments on commit dbeb177

Please sign in to comment.