mirror of
https://git.ryujinx.app/ryubing/ryujinx.git
synced 2025-12-16 16:37:03 +00:00
UI: Add keybinds to useful things
This commit is contained in:
parent
59b3ff7802
commit
741eba2798
13 changed files with 88 additions and 70 deletions
|
|
@ -33,7 +33,7 @@ namespace Ryujinx.Ava.UI.ViewModels
|
|||
private readonly string _amiiboJsonPath;
|
||||
private readonly byte[] _amiiboLogoBytes;
|
||||
private readonly HttpClient _httpClient;
|
||||
private readonly StyleableAppWindow _owner;
|
||||
private readonly AmiiboWindow _owner;
|
||||
|
||||
private Bitmap _amiiboImage;
|
||||
private List<AmiiboApi> _amiiboList;
|
||||
|
|
@ -49,7 +49,7 @@ namespace Ryujinx.Ava.UI.ViewModels
|
|||
|
||||
private static readonly AmiiboJsonSerializerContext _serializerContext = new(JsonHelper.GetDefaultSerializerOptions());
|
||||
|
||||
public AmiiboWindowViewModel(StyleableAppWindow owner, string lastScannedAmiiboId, string titleId)
|
||||
public AmiiboWindowViewModel(AmiiboWindow owner, string lastScannedAmiiboId, string titleId)
|
||||
{
|
||||
_owner = owner;
|
||||
|
||||
|
|
@ -186,6 +186,22 @@ namespace Ryujinx.Ava.UI.ViewModels
|
|||
}
|
||||
}
|
||||
|
||||
public void Scan()
|
||||
{
|
||||
if (AmiiboSelectedIndex > -1)
|
||||
{
|
||||
_owner.ScannedAmiibo = AmiiboList[AmiiboSelectedIndex];
|
||||
_owner.IsScanned = true;
|
||||
_owner.Close();
|
||||
}
|
||||
}
|
||||
|
||||
public void Cancel()
|
||||
{
|
||||
_owner.IsScanned = false;
|
||||
_owner.Close();
|
||||
}
|
||||
|
||||
public void Dispose()
|
||||
{
|
||||
GC.SuppressFinalize(this);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue