mirror of
https://git.ryujinx.app/ryubing/ryujinx.git
synced 2025-06-28 06:46:24 +02:00
UI: fix: when switching players, it would show old config (#122)
When switching between players' gamepads while saving settings, then returning to the previous player, the settings show the default settings instead of the actual settings applied
This commit is contained in:
parent
b17e4f79fb
commit
299be822c4
7 changed files with 119 additions and 7 deletions
|
@ -44,6 +44,7 @@ namespace Ryujinx.Ava.UI.ViewModels.Input
|
|||
private readonly MainWindow _mainWindow;
|
||||
|
||||
private PlayerIndex _playerId;
|
||||
private PlayerIndex _playerIdChoose;
|
||||
private int _controller;
|
||||
private string _controllerImage;
|
||||
private int _device;
|
||||
|
@ -83,6 +84,12 @@ namespace Ryujinx.Ava.UI.ViewModels.Input
|
|||
}
|
||||
}
|
||||
|
||||
public PlayerIndex PlayerIdChoose
|
||||
{
|
||||
get => _playerIdChoose;
|
||||
set { }
|
||||
}
|
||||
|
||||
public PlayerIndex PlayerId
|
||||
{
|
||||
get => _playerId;
|
||||
|
@ -90,6 +97,8 @@ namespace Ryujinx.Ava.UI.ViewModels.Input
|
|||
{
|
||||
if (IsModified)
|
||||
{
|
||||
|
||||
_playerIdChoose = value;
|
||||
return;
|
||||
}
|
||||
|
||||
|
@ -99,7 +108,9 @@ namespace Ryujinx.Ava.UI.ViewModels.Input
|
|||
if (!Enum.IsDefined(typeof(PlayerIndex), _playerId))
|
||||
{
|
||||
_playerId = PlayerIndex.Player1;
|
||||
|
||||
}
|
||||
_isLoaded = false;
|
||||
|
||||
LoadConfiguration();
|
||||
LoadDevice();
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue