Skip to content

Commit

Permalink
Created bool to store if the "Avilable Update" should be hidden on st…
Browse files Browse the repository at this point in the history
…artup (--hide-updates) (#272)

fixes #263
  • Loading branch information
nicola02nb authored Nov 19, 2024
1 parent f4b757c commit df5002b
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 1 deletion.
4 changes: 4 additions & 0 deletions src/Ryujinx.UI.Common/Helper/CommandLineState.cs
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,7 @@ public static class CommandLineState
public static string LaunchPathArg { get; private set; }
public static string LaunchApplicationId { get; private set; }
public static bool StartFullscreenArg { get; private set; }
public static bool HideAvailableUpdates { get; private set; }

public static void ParseArguments(string[] args)
{
Expand Down Expand Up @@ -93,6 +94,9 @@ public static void ParseArguments(string[] args)

OverrideHideCursor = args[++i];
break;
case "--hide-updates":
HideAvailableUpdates = true;
break;
case "--software-gui":
OverrideHardwareAcceleration = false;
break;
Expand Down
2 changes: 1 addition & 1 deletion src/Ryujinx/UI/Windows/MainWindow.axaml.cs
Original file line number Diff line number Diff line change
Expand Up @@ -383,7 +383,7 @@ private async Task CheckLaunchState()
await Dispatcher.UIThread.InvokeAsync(async () => await UserErrorDialog.ShowUserErrorDialog(UserError.NoKeys));
}

if (ConfigurationState.Instance.CheckUpdatesOnStart && Updater.CanUpdate())
if (ConfigurationState.Instance.CheckUpdatesOnStart && !CommandLineState.HideAvailableUpdates && Updater.CanUpdate())
{
await this.BeginUpdateAsync()
.ContinueWith(
Expand Down

0 comments on commit df5002b

Please sign in to comment.