mirror of
https://github.com/GreemDev/Ryujinx.git
synced 2024-11-27 19:30:50 +01:00
UI: Reload games list on locale change.
This commit is contained in:
parent
6ca57dd016
commit
c0cc3c4188
@ -2,6 +2,8 @@ using Avalonia;
|
||||
using Avalonia.Controls;
|
||||
using Avalonia.Input;
|
||||
using Avalonia.Interactivity;
|
||||
using Avalonia.Threading;
|
||||
using Ryujinx.Ava.Common.Locale;
|
||||
using Ryujinx.Ava.UI.Windows;
|
||||
using Ryujinx.Common.Configuration;
|
||||
using Ryujinx.Common.Logging;
|
||||
@ -27,6 +29,11 @@ namespace Ryujinx.Ava.UI.Views.Main
|
||||
{
|
||||
Window = window;
|
||||
DataContext = window.ViewModel;
|
||||
LocaleManager.Instance.LocaleChanged += () => Dispatcher.UIThread.Post(() =>
|
||||
{
|
||||
if (Window.ViewModel.EnableNonGameRunningControls)
|
||||
Refresh_OnClick(null, null);
|
||||
});
|
||||
}
|
||||
}
|
||||
|
||||
@ -48,10 +55,7 @@ namespace Ryujinx.Ava.UI.Views.Main
|
||||
ConfigurationState.Instance.Graphics.AspectRatio.Value = (int)aspectRatio + 1 > Enum.GetNames(typeof(AspectRatio)).Length - 1 ? AspectRatio.Fixed4x3 : aspectRatio + 1;
|
||||
}
|
||||
|
||||
private void Refresh_OnClick(object sender, RoutedEventArgs e)
|
||||
{
|
||||
Window.LoadApplications();
|
||||
}
|
||||
private void Refresh_OnClick(object sender, RoutedEventArgs e) => Window.LoadApplications();
|
||||
|
||||
private void VolumeStatus_OnPointerWheelChanged(object sender, PointerWheelEventArgs e)
|
||||
{
|
||||
|
Loading…
Reference in New Issue
Block a user