Rev | Line | |
---|
[12503] | 1 | using System;
|
---|
| 2 | using System.Collections.Generic;
|
---|
| 3 | using System.Linq;
|
---|
| 4 | using System.Text;
|
---|
| 5 | using System.Windows.Controls;
|
---|
| 6 |
|
---|
| 7 | namespace 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.