Index: Core/Common/src/Core.Common.Controls.TreeView/TreeViewControl.cs =================================================================== diff -u -rd501c71a57d85bd7080e023b4053162f6679e1c8 -rb1689a3cc2357a00e831ff7229278fcfcf129708 --- Core/Common/src/Core.Common.Controls.TreeView/TreeViewControl.cs (.../TreeViewControl.cs) (revision d501c71a57d85bd7080e023b4053162f6679e1c8) +++ Core/Common/src/Core.Common.Controls.TreeView/TreeViewControl.cs (.../TreeViewControl.cs) (revision b1689a3cc2357a00e831ff7229278fcfcf129708) @@ -161,7 +161,7 @@ return; } - AddRootNode(); + AddRootNodes(); treeView.SelectedNode = treeView.Nodes.Count > 0 ? treeView.Nodes[0] : null; } @@ -518,23 +518,40 @@ .FirstOrDefault(node => node != null); } - private void AddRootNode() + private void AddRootNodes() { + if (data is IEnumerable rootObjects) + { + foreach (object rootObject in rootObjects) + { + AddRootNode(rootObject); + } + } + else + { + TreeNode rootNode = AddRootNode(data); + + if (rootNode.Nodes.Count > 0) + { + rootNode.Expand(); + } + } + } + + private TreeNode AddRootNode(object rootObject) + { var rootNode = new TreeNode { - Tag = data + Tag = rootObject }; UpdateNode(rootNode); - if (rootNode.Nodes.Count > 0) - { - rootNode.Expand(); - } - treeView.Nodes.Add(rootNode); treeNodeObserverLookup.Add(rootNode, new TreeNodeObserver(rootNode, this)); + + return rootNode; } private TreeNode CreateTreeNode(TreeNode parentNode, object nodeData) Index: Riskeer/Integration/src/Riskeer.Integration.Plugin/RiskeerPlugin.cs =================================================================== diff -u -re6e019dca3ff110f39c0a5bb0b1a91eea916489d -rb1689a3cc2357a00e831ff7229278fcfcf129708 --- Riskeer/Integration/src/Riskeer.Integration.Plugin/RiskeerPlugin.cs (.../RiskeerPlugin.cs) (revision e6e019dca3ff110f39c0a5bb0b1a91eea916489d) +++ Riskeer/Integration/src/Riskeer.Integration.Plugin/RiskeerPlugin.cs (.../RiskeerPlugin.cs) (revision b1689a3cc2357a00e831ff7229278fcfcf129708) @@ -280,7 +280,17 @@ { if (project is RiskeerProject riskeerProject) { - return riskeerProject.AssessmentSections.First(); + AssessmentSection assessmentSection = riskeerProject.AssessmentSections.First(); + + return new object[] + { + new ReferenceLineContext(assessmentSection.ReferenceLine, assessmentSection), + new NormContext(assessmentSection.FailureMechanismContribution, assessmentSection), + new FailureMechanismContributionContext(assessmentSection.FailureMechanismContribution, assessmentSection), + new HydraulicBoundaryDatabaseContext(assessmentSection.HydraulicBoundaryDatabase, assessmentSection), + assessmentSection.BackgroundData, + assessmentSection.Comments + }; } return null; @@ -290,7 +300,7 @@ { if (project is RiskeerProject riskeerProject) { - return riskeerProject.AssessmentSections.First(); + return WrapFailureMechanismsInContexts(riskeerProject.AssessmentSections.First()); } return null; @@ -300,7 +310,7 @@ { if (project is RiskeerProject riskeerProject) { - return riskeerProject.AssessmentSections.First(); + return WrapFailureMechanismsInContexts(riskeerProject.AssessmentSections.First()); } return null; @@ -310,7 +320,15 @@ { if (project is RiskeerProject riskeerProject) { - return riskeerProject.AssessmentSections.First(); + AssessmentSection assessmentSection = riskeerProject.AssessmentSections.First(); + + return new object[] + { + new AssemblyResultCategoriesContext(assessmentSection), + new AssemblyResultTotalContext(assessmentSection), + new AssemblyResultPerSectionContext(assessmentSection), + new AssemblyResultPerSectionMapContext(assessmentSection) + }; } return null;