public PassthroughGroupVM(MainVM vm, TargetGroup group) : this(vm) { Do = group.Do; GameRelease = group.GameRelease; NicknameSuffix = group.NicknameSuffix; Passthroughs.AddRange(group.Targets.Select(t => new PassthroughVM(this, t))); }
public async Task Run(MainVM mvm) { Groups.AddRange(mvm.Groups .Where(g => g.Do) .Where(g => g.Passthroughs.Select(p => p.Do).Any()) .Select(g => new GroupTestVM(this, g))); await Task.WhenAll(Groups .SelectMany(g => g.Passthroughs.Items) .Select(t => Task.Run(t.Run))); }
public PassthroughGroupVM(MainVM vm) { Parent = vm; AddPassthroughCommand = ReactiveCommand.Create(() => { Passthroughs.Add(new PassthroughVM(this)); }); DeleteCommand = ReactiveCommand.Create(() => { vm.Groups.Remove(this); }); }