public async Task RunAsync() { var savedHighlights = _tree.HighlightedNodes; var settings = CreateSettings(); var solver = Tabs[_selectedTabIndex].CreateSolver(settings); var controllerResult = await _dialogCoordinator .ShowControllerDialogAsync(this, solver, Tabs[_selectedTabIndex].DisplayName, _tree); if (controllerResult != null) { _tree.SkilledNodes.Clear(); _tree.AllocateSkillNodes(controllerResult.Select(n => SkillTree.Skillnodes[n])); } _tree.HighlightedNodes.Clear(); _tree.HighlightedNodes.UnionWith(savedHighlights); _tree.DrawHighlights(); RunFinished?.Invoke(this, EventArgs.Empty); }
public async Task RunAsync() { var savedHighlights = _tree.HighlightedNodes; var settings = CreateSettings(); var solver = Tabs[_selectedTabIndex].CreateSolver(settings); var controllerResult = await _dialogCoordinator .ShowControllerDialogAsync(this, solver, Tabs[_selectedTabIndex].DisplayName, _tree); if (controllerResult != null) { _tree.SkilledNodes = new HashSet <ushort>(controllerResult); } _tree.HighlightedNodes = savedHighlights; _tree.DrawTreeComparisonHighlight(); _tree.DrawHighlights(); _tree.UpdateAvailNodes(); RunFinished.Raise(this); }