mirror of
https://github.com/Ryubing/Ryujinx.git
synced 2025-03-10 17:14:25 +00:00
misc: chore: Use UpdateCommand instance for the normal Check for Updates button
This commit is contained in:
parent
9cb5f5689b
commit
30fef8e96e
@ -107,7 +107,7 @@ namespace Ryujinx.Ava.UI.ViewModels
|
|||||||
[ObservableProperty] private ApplicationContextMenu _gridAppContextMenu;
|
[ObservableProperty] private ApplicationContextMenu _gridAppContextMenu;
|
||||||
[ObservableProperty] private bool _updateAvailable;
|
[ObservableProperty] private bool _updateAvailable;
|
||||||
|
|
||||||
public static AsyncRelayCommand UpdateCommand => Commands.Create(async () =>
|
public static AsyncRelayCommand UpdateCommand { get; } = Commands.Create(async () =>
|
||||||
{
|
{
|
||||||
if (Updater.CanUpdate(true))
|
if (Updater.CanUpdate(true))
|
||||||
await Updater.BeginUpdateAsync(true);
|
await Updater.BeginUpdateAsync(true);
|
||||||
|
@ -52,11 +52,7 @@ namespace Ryujinx.Ava.UI.Views.Main
|
|||||||
AboutWindowMenuItem.Command = Commands.Create(AboutWindow.Show);
|
AboutWindowMenuItem.Command = Commands.Create(AboutWindow.Show);
|
||||||
CompatibilityListMenuItem.Command = Commands.Create(() => CompatibilityList.Show());
|
CompatibilityListMenuItem.Command = Commands.Create(() => CompatibilityList.Show());
|
||||||
|
|
||||||
UpdateMenuItem.Command = Commands.Create(async () =>
|
UpdateMenuItem.Command = MainWindowViewModel.UpdateCommand;
|
||||||
{
|
|
||||||
if (Updater.CanUpdate(true))
|
|
||||||
await Updater.BeginUpdateAsync(true);
|
|
||||||
});
|
|
||||||
|
|
||||||
FaqMenuItem.Command =
|
FaqMenuItem.Command =
|
||||||
SetupGuideMenuItem.Command =
|
SetupGuideMenuItem.Command =
|
||||||
|
Loading…
x
Reference in New Issue
Block a user