/// <summary> /// Refills the ResultList by merging a new item from the childs /// </summary> private void RefillResults() { SearchNode currentNode = ChildNode; Item newItemToInsert = null; int currentPriority = -1; while (currentNode?.NextNode != null) { var tmp = currentNode.ResultItems.FirstOrDefault(item => !ResultItems.Contains(item)); if (tmp != null && tmp.Priority > currentPriority) { newItemToInsert = tmp; currentPriority = tmp.Priority; } currentNode = currentNode.NextNode; } if (newItemToInsert != null) { Results.Add(newItemToInsert); } }