7 types derived from ToolStripDropDownItem
System.Windows.Forms (3)
System\Windows\Forms\Controls\ToolStrips\ToolStripDropDownButton.cs (1)
15public partial class ToolStripDropDownButton : ToolStripDropDownItem
System\Windows\Forms\Controls\ToolStrips\ToolStripMenuItem.cs (1)
20public partial class ToolStripMenuItem : ToolStripDropDownItem
System\Windows\Forms\Controls\ToolStrips\ToolStripSplitButton.cs (1)
13public partial class ToolStripSplitButton : ToolStripDropDownItem
System.Windows.Forms.Tests (4)
System\Windows\Forms\AccessibleObjects\ToolStripDropDownItemAccessibleObjectTests.cs (1)
221private class SubToolStripDropDownItem : ToolStripDropDownItem
System\Windows\Forms\ToolStripDropDownItemTests.cs (2)
471private class CustomCreateDefaultDropDownToolStripDropDownItem : ToolStripDropDownItem 491private class SubToolStripDropDownItem : ToolStripDropDownItem
System\Windows\Forms\ToolStripItemTests.cs (1)
15624private class ToolStripDropDownItemWithAccessibleObjectFieldAccessor : ToolStripDropDownItem
178 references to ToolStripDropDownItem
System.Windows.Forms (24)
System\Windows\Forms\Controls\ToolStrips\ToolStrip.cs (4)
1800&& displayedItems[i] is ToolStripDropDownItem dropDownItem 2475if (dismissingItem is ToolStripDropDownItem item && !item.HasDropDownItems) 3317if (!IsDropDown && (!(item is ToolStripDropDownItem))) 3939if (toolStripItem is ToolStripDropDownItem dropDownItem && dropDownItem.DropDownItems.Count > 0)
System\Windows\Forms\Controls\ToolStrips\ToolStripDropDown.cs (5)
630internal ToolStripDropDownItem? OwnerDropDownItem 632get { return OwnerItem as ToolStripDropDownItem; } 991Point screenPoint = _ownerItem is ToolStripDropDownItem dropDownItem 1002Point parentClientPoint = (_ownerItem is ToolStripDropDownItem dropDownItem) && (ParentInternal is not null) 1133if ((!(e.ClickedItem is ToolStripDropDownItem dismissingItem)) // it's not a dropdownitem
System\Windows\Forms\Controls\ToolStrips\ToolStripDropDownItem.cs (5)
766Stack<ToolStripDropDownItem> itemsStack = new(); 772var item = itemsStack.Pop(); 796if (typeof(ToolStripDropDownItem).IsAssignableFrom(childItem.GetType())) 798if (((ToolStripDropDownItem)childItem)._dropDown is not null) 800itemsStack.Push((ToolStripDropDownItem)childItem);
System\Windows\Forms\Controls\ToolStrips\ToolStripDropDownItemAccessibleObject.cs (3)
12private readonly ToolStripDropDownItem _owner; 14public ToolStripDropDownItemAccessibleObject(ToolStripDropDownItem item) : base(item) 35if (Owner is ToolStripDropDownItem item && item.HasDropDownItems)
System\Windows\Forms\Controls\ToolStrips\ToolStripItemCollection.cs (1)
277if (itemsToLookIn[j] is not ToolStripDropDownItem item)
System\Windows\Forms\Controls\ToolStrips\ToolStripManager.cs (2)
1160if (item is ToolStripDropDownItem tsddownDest && source is ToolStripDropDownItem tsddownSrc && tsddownSrc.DropDownItems.Count != 0)
System\Windows\Forms\Controls\ToolStrips\ToolstripProfessionalRenderer.cs (2)
228if (e.Item is ToolStripDropDownItem item && item.Pressed && item.HasDropDownItems) 679if (item is ToolStripDropDownItem)
System\Windows\Forms\Controls\ToolStrips\ToolStripRenderEventArgs.cs (2)
98ToolStripDropDownItem? ownerItem = dropDown.OwnerItem as ToolStripDropDownItem;
System.Windows.Forms.Design (117)
System\Windows\Forms\Design\BindingNavigatorDesigner.cs (2)
110ToolStripDropDownItem? dropDownItem = item as ToolStripDropDownItem;
System\Windows\Forms\Design\TemplateNodeCustomMenuItemCollection.cs (1)
138if (parentDropDown.OwnerItem is ToolStripDropDownItem ownerItem)
System\Windows\Forms\Design\ToolStripContainerDesigner.cs (2)
290private bool CheckDropDownBounds(ToolStripDropDownItem dropDownItem, Glyph childGlyph, GlyphCollection glyphs) 314if (component is ToolStripDropDownItem item)
System\Windows\Forms\Design\ToolStripDesigner.cs (12)
785ToolStripDropDown topmost = ToolStripItemDesigner.GetFirstDropDown((ToolStripDropDownItem)(ownerItem)); 800ToolStripDropDown topmost = ToolStripItemDesigner.GetFirstDropDown((ToolStripDropDownItem)parentItem); 826if (SelectionService.PrimarySelection is ToolStripDropDownItem selectedItem) 842if (parent.OwnerItem is ToolStripDropDownItem ownerItem) 1118if (e.Component is ToolStripDropDownItem dropDownItem) 1909if (primaryItem is ToolStripDropDownItem primaryDropDownItem) 1996if (_toolStripAdornerWindowService is not null && sender is ToolStripDropDownItem ddi) 2025ToolStripDropDownItem ddi = sender as ToolStripDropDownItem; 2071ToolStripDropDownItem ddi = sender as ToolStripDropDownItem; 2135if (SelectionService.PrimarySelection is ToolStripDropDownItem selectedItem)
System\Windows\Forms\Design\ToolStripDesignerUtils.cs (2)
92if (stripItem is not ToolStripDropDownItem) 98parent = ((ToolStripDropDownItem)stripItem).DropDown;
System\Windows\Forms\Design\ToolStripDropDownDesigner.cs (2)
437if (comp is ToolStripDropDownItem currentItem) 472topmost = ToolStripItemDesigner.GetFirstDropDown((ToolStripDropDownItem)ownerItem);
System\Windows\Forms\Design\ToolStripDropDownItemDesigner.cs (1)
28if (Component is ToolStripDropDownItem item && item.DropDown.IsAutoGenerated)
System\Windows\Forms\Design\ToolStripInSituService.cs (1)
99if (dropDown.OwnerItem is ToolStripDropDownItem parentItem)
System\Windows\Forms\Design\ToolStripItemBehavior.cs (5)
604if (glyphItem is ToolStripDropDownItem ddItem) 615ToolStripDropDownItem ownerItem = dropDown.OwnerItem as ToolStripDropDownItem; 793if (item is ToolStripDropDownItem) 803if (dropDown.OwnerItem is ToolStripDropDownItem ownerItem)
System\Windows\Forms\Design\ToolStripItemCustomMenuItemCollection.cs (2)
205if (_currentItem is ToolStripDropDownItem) 377if (parent.OwnerItem is ToolStripDropDownItem ownerItem)
System\Windows\Forms\Design\ToolStripItemDesigner.cs (19)
182if (ToolStripItem is ToolStripDropDownItem) 184ToolStripDropDownItem item = ToolStripItem as ToolStripDropDownItem; 429if (newItem is ToolStripDropDownItem dropDown) 525private void FireComponentChanging(ToolStripDropDownItem parent) 540if (item is ToolStripDropDownItem dropDownItem && dropDownItem.DropDownItems.Count > 1 /*including TN*/) 547private void FireComponentChanged(ToolStripDropDownItem parent) 562if (item is ToolStripDropDownItem dropDownItem && dropDownItem.DropDownItems.Count > 1 /*including TN*/) 678if (site is not null && Component is ToolStripDropDownItem) 766ToolStripDropDownItem dropDownItem = ToolStripItem as ToolStripDropDownItem; 767if (dropDownItem is not null && typeof(ToolStripDropDownItem).IsAssignableFrom(t)) 800if (component is ToolStripDropDownItem) 991if (parentDropDown.OwnerItem is ToolStripDropDownItem parentItem) 1113if (ToolStripItem is ToolStripDropDownItem) 1146private static void SerializeDropDownItems(ToolStripDropDownItem parent, ref SerializationStore _serializedDataForDropDownItems, ComponentSerializationService _serializationService) 1154if (item is ToolStripDropDownItem dropDownItem) 1284if (ToolStripItem is ToolStripDropDownItem) // We have no place to show this item... so Hide the DropDown 1286if (ToolStripItem is ToolStripDropDownItem ddItem)
System\Windows\Forms\Design\ToolStripKeyboardHandlingService.cs (13)
530if (cutCommand && OwnerItemAfterCut is ToolStripDropDownItem parentItem) 642if (parentDropDown.OwnerItem is ToolStripDropDownItem ownerItem) 652if (selSvc.PrimarySelection is ToolStripDropDownItem dropDownItem && dropDownItem.DropDown.Visible) 850ToolStripDropDownItem ownerItem = (ToolStripDropDownItem)((ToolStripDropDown)(typeHereNode.Owner)).OwnerItem; 945ToolStripDropDownItem ownerItem = (ToolStripDropDownItem)((ToolStripDropDown)(typeHereNode.Owner)).OwnerItem; 1239item = ShiftPrimaryItem as ToolStripDropDownItem; 1242item ??= SelectedDesignerControl as ToolStripDropDownItem; 1251&& item is ToolStripDropDownItem dropDownItem) 1368ToolStripDropDownItem dropDownItem = item as ToolStripDropDownItem; 1851ToolStripDropDown dropDown = ToolStripItemDesigner.GetFirstDropDown((ToolStripDropDownItem)parentItem);
System\Windows\Forms\Design\ToolStripMenuItemDesigner.cs (44)
246private ToolStripDropDownItem MenuItem 248get => ToolStripItem as ToolStripDropDownItem; 294ToolStripDropDownItem parentItem = dropDown.OwnerItem as ToolStripDropDownItem; 405private void AddBodyGlyphs(ToolStripDropDownItem item) 602if (MenuItem.DropDownItems[index] is ToolStripDropDownItem currentItem) 928private static bool CheckSameOwner(ToolStripDropDownItem lastSelected, ToolStripDropDownItem currentSelected) 953if (MenuItem.DropDownItems[index] is ToolStripDropDownItem newItem) 965ToolStripDropDownItem currentItem = MenuItem; 968currentItem = (ToolStripDropDownItem)dropDown.OwnerItem; 1109ToolStripDropDownItem ddi = sender as ToolStripDropDownItem; 1121ToolStripDropDownItem ddi = sender as ToolStripDropDownItem; 1143if (sender is ToolStripDropDownItem ddi) 1253ToolStripDropDownItem selectedItem = null; 1258selectedItem = ((ToolStripDropDown)item.Owner).OwnerItem as ToolStripDropDownItem; 1263selectedItem = _selectionService.PrimarySelection as ToolStripDropDownItem; 1372ToolStripDropDownItem dropDownItem = toolItem as ToolStripDropDownItem; 1424private void HideAllDropDowns(ToolStripDropDownItem item) 1440item = (ToolStripDropDownItem)itemDropDown.OwnerItem; 1457private void HideSiblingDropDowns(ToolStripDropDownItem item) 1467item = (ToolStripDropDownItem)dropDown.OwnerItem; 1541internal void InitializeBodyGlyphsForItems(bool addGlyphs /* true for add */, ToolStripDropDownItem item) 1576if (MenuItem.DropDown.OwnerItem is ToolStripDropDownItem currentOwner && currentOwner != MenuItem) 1625if (startDropDown.OwnerItem is ToolStripDropDownItem ownerItem) 1882ToolStripDropDownItem ownerItem = (ToolStripDropDownItem)owner.OwnerItem; 1965ToolStripDropDownItem ownerItem = (ToolStripDropDownItem)owner.OwnerItem; 1972if (itemToBeDeleted is ToolStripDropDownItem dropDownItem) 2312internal void RemoveTypeHereNode(ToolStripDropDownItem ownerItem) 2347ToolStripDropDownItem editedItem = (ToolStripDropDownItem)MenuItem.DropDownItems[index + 1]; 2372private void RemoveBodyGlyphs(ToolStripDropDownItem item) 2415internal void ResetGlyphs(ToolStripDropDownItem item) 2534private void SelectItems(ToolStripDropDownItem oldSelection, ISelectionService selSvc) 2554internal void ShowOwnerDropDown(ToolStripDropDownItem currentSelection) 2561currentSelection = (ToolStripDropDownItem)currentDropDown.OwnerItem; 2684ToolStripDropDownItem ownerItem = null; 2687ownerItem = parentToolStrip.OwnerItem as ToolStripDropDownItem; 2762if (primaryItem is ToolStripDropDownItem dropDownItem)
System\Windows\Forms\Design\ToolStripTemplateNode.cs (11)
694if (_component is ToolStripDropDownItem stripItem) 888if (_activeItem is ToolStripDropDownItem item && !item.IsOnDropDown) 1230ToolStripDropDownItem stripItem = sender as ToolStripDropDownItem; 1344if (_component is ToolStripDropDownItem stripItem) 1377if (currentItem is ToolStripDropDownItem) 1481if (currentItem is ToolStripDropDownItem stripItem) 1498if (currentItem is MenuStrip or ToolStripDropDownItem) 1681if (_currentItem is ToolStripDropDownItem) 1738if (_currentItem is ToolStripDropDownItem) 1854if (_owner._component is MenuStrip or ToolStripDropDownItem)
System.Windows.Forms.Tests (37)
System\Windows\Forms\AccessibleObjects\ToolStripDropDownMenu.ToolStripDropDownMenuAccessibleObjectTests.cs (31)
12IEnumerable<Type> types = ReflectionHelper.GetPublicNotAbstractClasses<ToolStripDropDownItem>().Select(type => type); 33using ToolStripDropDownItem item = ReflectionHelper.InvokePublicConstructor<ToolStripDropDownItem>(itemType); 79IEnumerable<Type> types = ReflectionHelper.GetPublicNotAbstractClasses<ToolStripDropDownItem>().Select(type => type); 108using ToolStripDropDownItem ownerItem = ReflectionHelper.InvokePublicConstructor<ToolStripDropDownItem>(ownerType); 109using ToolStripDropDownItem parentItem1 = ReflectionHelper.InvokePublicConstructor<ToolStripDropDownItem>(parentType); 110using ToolStripDropDownItem parentItem2 = ReflectionHelper.InvokePublicConstructor<ToolStripDropDownItem>(parentType); 111using ToolStripDropDownItem childItem1 = ReflectionHelper.InvokePublicConstructor<ToolStripDropDownItem>(childType); 112using ToolStripDropDownItem childItem2 = ReflectionHelper.InvokePublicConstructor<ToolStripDropDownItem>(childType); 113using ToolStripDropDownItem childItem3 = ReflectionHelper.InvokePublicConstructor<ToolStripDropDownItem>(childType); 114using ToolStripDropDownItem childItem4 = ReflectionHelper.InvokePublicConstructor<ToolStripDropDownItem>(childType); 171IEnumerable<Type> types = ReflectionHelper.GetPublicNotAbstractClasses<ToolStripDropDownItem>().Select(type => type); 193using ToolStripDropDownItem parentItem1 = ReflectionHelper.InvokePublicConstructor<ToolStripDropDownItem>(parentType); 194using ToolStripDropDownItem parentItem2 = ReflectionHelper.InvokePublicConstructor<ToolStripDropDownItem>(parentType); 195using ToolStripDropDownItem childItem1 = ReflectionHelper.InvokePublicConstructor<ToolStripDropDownItem>(childType); 196using ToolStripDropDownItem childItem2 = ReflectionHelper.InvokePublicConstructor<ToolStripDropDownItem>(childType); 197using ToolStripDropDownItem childItem3 = ReflectionHelper.InvokePublicConstructor<ToolStripDropDownItem>(childType); 198using ToolStripDropDownItem childItem4 = ReflectionHelper.InvokePublicConstructor<ToolStripDropDownItem>(childType);
System\Windows\Forms\AccessibleObjects\ToolStripScrollButton.ToolStripScrollButtonAccessibleObjectTests.cs (6)
12IEnumerable<Type> types = ReflectionHelper.GetPublicNotAbstractClasses<ToolStripDropDownItem>().Select(type => type); 33using ToolStripDropDownItem ownerItem = ReflectionHelper.InvokePublicConstructor<ToolStripDropDownItem>(itemType); 95using ToolStripDropDownItem ownerItem = ReflectionHelper.InvokePublicConstructor<ToolStripDropDownItem>(itemType); 133using ToolStripDropDownItem ownerItem = new ToolStripDropDownButton();