OpenModlistProperties blocked from executing when UI not ready

Was like this way before, but XAML modifications from previous commits removed the logic.  This readds it via the Command canExecute features
This commit is contained in:
Justin Swanson 2019-10-13 15:15:06 -05:00
parent 123c7c8b7b
commit 87f44b94cf

View File

@ -1,4 +1,4 @@
using Syroot.Windows.IO;
using Syroot.Windows.IO;
using System;
using ReactiveUI;
using System.Collections.Generic;
@ -89,7 +89,10 @@ namespace Wabbajack
this.ChangeDownloadPathCommand = ReactiveCommand.Create(ExecuteChangeDownloadPath);
this.ShowReportCommand = ReactiveCommand.Create(ShowReport);
this.VisitNexusSiteCommand = ReactiveCommand.Create(VisitNexusSite);
this.OpenModListPropertiesCommand = ReactiveCommand.Create(OpenModListProperties);
this.OpenModListPropertiesCommand = ReactiveCommand.Create(
execute: OpenModListProperties,
canExecute: this.WhenAny(x => x.UIReady)
.ObserveOnGuiThread());
this.OpenReadmeCommand = ReactiveCommand.Create(
execute: this.OpenReadmeWindow,
canExecute: this.WhenAny(x => x.ModList)