mirror of
https://git.ryujinx.app/ryubing/ryujinx.git
synced 2025-06-28 06:46:24 +02:00
UI: --install-firmware
startup flag.
Has the normal UI flow, this is just for systems where the file picker doesn't show up.
This commit is contained in:
parent
de16d8fa3e
commit
c2ed0fd5fd
4 changed files with 32 additions and 4 deletions
|
@ -139,8 +139,21 @@ namespace Ryujinx.Ava.UI.Windows
|
|||
base.OnApplyTemplate(e);
|
||||
|
||||
NotificationHelper.SetNotificationManager(this);
|
||||
|
||||
Executor.ExecuteBackgroundAsync(ShowIntelMacWarningAsync);
|
||||
|
||||
Executor.ExecuteBackgroundAsync(async () =>
|
||||
{
|
||||
await ShowIntelMacWarningAsync();
|
||||
FilePath firmwarePath = CommandLineState.FirmwareToInstallPathArg;
|
||||
if (firmwarePath is not null)
|
||||
{
|
||||
if ((firmwarePath.ExistsAsFile && firmwarePath.Extension is "xci" or "zip") ||
|
||||
firmwarePath.ExistsAsDirectory)
|
||||
await Dispatcher.UIThread.InvokeAsync(() =>
|
||||
ViewModel.HandleFirmwareInstallation(firmwarePath));
|
||||
else
|
||||
Logger.Notice.Print(LogClass.UI, "Invalid firmware type provided. Path must be a directory, or a .zip or .xci file.");
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
private void OnScalingChanged(object sender, EventArgs e)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue