mirror of
https://git.naxdy.org/Mirror/Ryujinx.git
synced 2025-01-14 22:50:34 +00:00
Refresh support for GTK
This commit is contained in:
parent
51d5a7b16f
commit
8eb68aa2aa
2 changed files with 7 additions and 3 deletions
|
@ -1648,7 +1648,7 @@ namespace Ryujinx.Ui
|
|||
|
||||
private void ManageUserProfiles_Pressed(object sender, EventArgs args)
|
||||
{
|
||||
UserProfilesManagerWindow userProfilesManagerWindow = new UserProfilesManagerWindow(_accountManager, _contentManager, _virtualFileSystem);
|
||||
UserProfilesManagerWindow userProfilesManagerWindow = new UserProfilesManagerWindow(_accountManager, _contentManager, _virtualFileSystem, UpdateGameTable);
|
||||
|
||||
userProfilesManagerWindow.SetSizeRequest((int)(userProfilesManagerWindow.DefaultWidth * Program.WindowScaleFactor), (int)(userProfilesManagerWindow.DefaultHeight * Program.WindowScaleFactor));
|
||||
userProfilesManagerWindow.Show();
|
||||
|
|
|
@ -13,7 +13,6 @@ using System.Reflection;
|
|||
using System.Threading;
|
||||
using System.Threading.Tasks;
|
||||
using Image = SixLabors.ImageSharp.Image;
|
||||
using UserId = Ryujinx.HLE.HOS.Services.Account.Acc.UserId;
|
||||
|
||||
namespace Ryujinx.Ui.Windows
|
||||
{
|
||||
|
@ -24,6 +23,9 @@ namespace Ryujinx.Ui.Windows
|
|||
private readonly AccountManager _accountManager;
|
||||
private readonly ContentManager _contentManager;
|
||||
|
||||
public delegate void ChangedUserDelegate();
|
||||
private readonly ChangedUserDelegate _changedUserDelegate;
|
||||
|
||||
private byte[] _bufferImageProfile;
|
||||
private string _tempNewProfileName;
|
||||
|
||||
|
@ -31,7 +33,7 @@ namespace Ryujinx.Ui.Windows
|
|||
|
||||
private ManualResetEvent _avatarsPreloadingEvent = new ManualResetEvent(false);
|
||||
|
||||
public UserProfilesManagerWindow(AccountManager accountManager, ContentManager contentManager, VirtualFileSystem virtualFileSystem) : base($"Ryujinx {Program.Version} - Manage User Profiles")
|
||||
public UserProfilesManagerWindow(AccountManager accountManager, ContentManager contentManager, VirtualFileSystem virtualFileSystem, ChangedUserDelegate changedUserDelegate) : base($"Ryujinx {Program.Version} - Manage User Profiles")
|
||||
{
|
||||
Icon = new Gdk.Pixbuf(Assembly.GetAssembly(typeof(ConfigurationState)), "Ryujinx.Ui.Common.Resources.Logo_Ryujinx.png");
|
||||
|
||||
|
@ -44,6 +46,7 @@ namespace Ryujinx.Ui.Windows
|
|||
|
||||
_accountManager = accountManager;
|
||||
_contentManager = contentManager;
|
||||
_changedUserDelegate = changedUserDelegate;
|
||||
|
||||
CellRendererToggle userSelectedToggle = new CellRendererToggle();
|
||||
userSelectedToggle.Toggled += UserSelectedToggle_Toggled;
|
||||
|
@ -128,6 +131,7 @@ namespace Ryujinx.Ui.Windows
|
|||
|
||||
// Open the selected one.
|
||||
_accountManager.OpenUser(new UserId(userId));
|
||||
_changedUserDelegate();
|
||||
|
||||
_deleteButton.Sensitive = userId != AccountManager.DefaultUserId.ToString();
|
||||
|
||||
|
|
Loading…
Reference in a new issue