Bug fixes, functionality improvements:

Now the profile changes immediately upon selection.
The icon for restoring settings has been changed.
A bug has been fixed where restoring settings did not restore the previously selected gamepad.
This commit is contained in:
Vova
2025-03-02 19:07:49 +10:00
parent 33e3ba9ff2
commit 299f2144c8
3 changed files with 48 additions and 18 deletions

View File

@@ -87,7 +87,7 @@
ToolTip.Tip="{ext:Locale ControllerSettingsCancelCurrentChangesToolTip}"
Command="{Binding LoadSavedConfiguration}">
<ui:SymbolIcon
Symbol="Cancel"
Symbol="Undo"
FontSize="15"
Height="20" />
</Button>
@@ -117,7 +117,8 @@
Name="ProfileBox"
HorizontalAlignment="Stretch"
VerticalAlignment="Center"
SelectedIndex="{Binding ProfileChoose}"
SelectedItem="{Binding ProfileChoose, Mode=TwoWay}"
SelectionChanged="ComboBox_SelectionChanged"
ItemsSource="{Binding ProfilesList}"
Text="{Binding ProfileName, Mode=TwoWay}" />
<Button
@@ -126,7 +127,7 @@
Margin="5,0,0,0"
VerticalAlignment="Center"
ToolTip.Tip="{ext:Locale ControllerSettingsLoadProfileToolTip}"
Command="{Binding LoadProfile}">
Command="{Binding LoadProfileButton}">
<ui:SymbolIcon
Symbol="View"
FontSize="15"

View File

@@ -1,4 +1,5 @@
using Avalonia.Controls;
using FluentAvalonia.UI.Controls;
using Ryujinx.Ava.Common.Locale;
using Ryujinx.Ava.UI.Helpers;
using Ryujinx.Ava.UI.Models;
@@ -65,11 +66,19 @@ namespace Ryujinx.Ava.UI.Views.Input
ViewModel.IsModified = false;
ViewModel.PlayerId = ViewModel.PlayerIdChoose;
}
}
}
private void ComboBox_SelectionChanged(object sender, SelectionChangedEventArgs e)
{
if (sender is FAComboBox faComboBox)
{
faComboBox.IsDropDownOpen = false;
ViewModel.IsModified = true;
}
}
public void Dispose()
{