Offloaded MO2InstallerVM's validity check to the background thread

This commit is contained in:
Justin Swanson 2019-12-24 00:48:47 -06:00
parent d30f81ecbd
commit 1be9b49ae9

View File

@ -58,10 +58,10 @@ namespace Wabbajack
Location.AdditionalError = Observable.CombineLatest(
this.WhenAny(x => x.Location.TargetPath),
this.WhenAny(x => x.DownloadLocation.TargetPath),
resultSelector: (target, download) =>
{
return MO2Installer.CheckValidInstallPath(target, download);
});
resultSelector: (target, download) => (target, download))
.ObserveOn(RxApp.MainThreadScheduler)
.Select(i => MO2Installer.CheckValidInstallPath(i.target, i.download))
.ObserveOnGuiThread();
CanInstall = Observable.CombineLatest(
this.WhenAny(x => x.Location.InError),