Free cookie consent management tool by TermsFeed Policy Generator

source: branches/HeuristicLab.Problems.GrammaticalOptimization/DynamicDataDisplay/Common/Auxiliary/MenuItemExtensions.cs @ 13792

Last change on this file since 13792 was 12503, checked in by aballeit, 9 years ago

#2283 added GUI and charts; fixed MCTS

File size: 453 bytes
Line 
1using System;
2using System.Collections.Generic;
3using System.Linq;
4using System.Text;
5using System.Windows.Controls;
6
7namespace Microsoft.Research.DynamicDataDisplay.Common.Auxiliary
8{
9  internal static class MenuItemExtensions
10  {
11    public static MenuItem FindChildByHeader(this MenuItem parent, string header)
12    {
13      return parent.Items.OfType<MenuItem>().Where(subMenu => (string)subMenu.Header == header).FirstOrDefault();
14    }
15  }
16}
Note: See TracBrowser for help on using the repository browser.