mirror of
https://github.com/aaru-dps/Aaru.git
synced 2025-12-16 19:24:25 +00:00
[GUI] Update AboutViewModel to add assemblies on the UI thread
This commit is contained in:
@@ -40,6 +40,7 @@ using System.Threading.Tasks;
|
|||||||
using System.Windows.Input;
|
using System.Windows.Input;
|
||||||
using Aaru.Gui.Models;
|
using Aaru.Gui.Models;
|
||||||
using Aaru.Gui.Views.Dialogs;
|
using Aaru.Gui.Views.Dialogs;
|
||||||
|
using Avalonia.Threading;
|
||||||
using CommunityToolkit.Mvvm.ComponentModel;
|
using CommunityToolkit.Mvvm.ComponentModel;
|
||||||
using CommunityToolkit.Mvvm.Input;
|
using CommunityToolkit.Mvvm.Input;
|
||||||
using JetBrains.Annotations;
|
using JetBrains.Annotations;
|
||||||
@@ -78,10 +79,13 @@ public sealed partial class AboutViewModel : ViewModelBase
|
|||||||
|
|
||||||
if(name is null || version is null) continue;
|
if(name is null || version is null) continue;
|
||||||
|
|
||||||
Assemblies.Add(new AssemblyModel
|
Dispatcher.UIThread.Invoke(() =>
|
||||||
{
|
{
|
||||||
Name = name,
|
Assemblies.Add(new AssemblyModel
|
||||||
Version = version
|
{
|
||||||
|
Name = name,
|
||||||
|
Version = version
|
||||||
|
});
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
|||||||
Reference in New Issue
Block a user