Merge pull request #1062 from erri120/show-manifest-fix

Added canExecute to ShowManifestCommand
This commit is contained in:
Timothy Baldridge 2020-09-07 21:07:57 -06:00 committed by GitHub
commit 1207b23297
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -308,11 +308,13 @@ namespace Wabbajack
})
.ToGuiProperty(this, nameof(ModListName));
// Define commands
ShowManifestCommand = ReactiveCommand.Create(() =>
{
new ManifestWindow(ModList.SourceModList).Show();
});
}, this.WhenAny(x => x.ModList)
.Select(x => x?.SourceModList != null)
.ObserveOnGuiThread());
OpenReadmeCommand = ReactiveCommand.Create(
execute: () => this.ModList?.OpenReadme(),
canExecute: this.WhenAny(x => x.ModList)