12 writes to DropDown
System.Windows.Forms (3)
System\Windows\Forms\Controls\ToolStrips\ToolStripDropDownItem.cs (1)
67DropDown = CreateDefaultDropDown();
System\Windows\Forms\Controls\ToolStrips\ToolStripDropDownMenu.cs (1)
262((ToolStripMenuItem)itemToAdd).DropDown = FromHMenu(info.hSubMenu, targetWindow);
System\Windows\Forms\MDI\MDIControlStrip.cs (1)
138_system.DropDown = ToolStripDropDownMenu.FromHMenu(PInvoke.GetSystemMenu(GetSafeHandle(_target), bRevert: false), _target);
System.Windows.Forms.Design (9)
System\Windows\Forms\Design\TableLayoutPanelDesigner.cs (2)
153DropDown = rowMenu, 159DropDown = colMenu,
System\Windows\Forms\Design\TemplateNodeCustomMenuItemCollection.cs (1)
41DropDown = ToolStripDesignerUtils.GetNewItemDropDown(ParentTool, _currentItem, new EventHandler(AddNewItemClick), false, _serviceProvider, true)
System\Windows\Forms\Design\ToolStripDropDownDesigner.cs (1)
656_menuItem.DropDown = _dropDown;
System\Windows\Forms\Design\ToolStripItemCustomMenuItemCollection.cs (2)
195DropDown = ToolStripDesignerUtils.GetNewItemDropDown(ParentTool, _currentItem, new EventHandler(AddNewItemClick), true, _serviceProvider, true) 200DropDown = ToolStripDesignerUtils.GetNewItemDropDown(ParentTool, _currentItem, new EventHandler(AddNewItemClick), false, _serviceProvider, true)
System\Windows\Forms\Design\ToolStripMenuItemDesigner.cs (2)
167MenuItem.DropDown = value; 1977MenuItem.DropDown = null;
System\Windows\Forms\Design\ToolStripTemplateNode.cs (1)
1384_addItemButton.DropDown = _contextMenu;
226 references to DropDown
System.Windows.Forms (82)
System\Windows\Forms\Controls\ToolStrips\ToolStrip.cs (10)
1633OverflowButton.DropDown.ShowItemToolTips = value; 1966CommonProperties.xClearPreferredSizeCache(OverflowButton.DropDown); 1967OverflowButton.DropDown.LayoutRequired = true; 1971LayoutTransaction.DoLayout(OverflowButton.DropDown, e.Item, PropertyNames.Items); 1972OverflowButton.DropDown.Invalidate(); 1983OverflowButton.DropDown.LayoutRequired = true; 1991|| !OverflowButton.DropDown.Visible 1992|| !OverflowButton.DropDown.IsHandleCreated; 2003return (_toolStripOverflowButton is null || !_toolStripOverflowButton.HasDropDown) ? null : _toolStripOverflowButton.DropDown as ToolStripOverflow; 2461OverflowButton.DropDown.HandleItemClick(dismissingItem);
System\Windows\Forms\Controls\ToolStrips\ToolStripDropDown.cs (2)
650return _ownerItem.Owner.OverflowButton.DropDown; 1131|| (dismissingItem is ToolStripSplitButton && !dismissingItem.DropDown.Visible) // clicking on the split button button dismisses
System\Windows\Forms\Controls\ToolStrips\ToolStripDropDownButton.cs (3)
134if (DropDown.Visible) 136ToolStripManager.ModalMenuFilter.CloseActiveDropDown(DropDown, ToolStripDropDownCloseReason.AppClicked); 160ToolStripManager.ModalMenuFilter.CloseActiveDropDown(DropDown, ToolStripDropDownCloseReason.AppClicked);
System\Windows\Forms\Controls\ToolStrips\ToolStripDropDownItem.cs (24)
186if (HasDropDownItems && DropDown.Visible) 188DropDown.Location = DropDownLocation; 245=> DropDown.Items; 275if (DropDown.AutoClose || !IsInDesignMode || (IsInDesignMode && !IsOnDropDown)) 277return DropDown.OwnerItem == this && DropDown.Visible; 379Rectangle dropDownBounds = new(Point.Empty, DropDown.GetSuggestedSize()); 416DropDown.Visible = false; 445if (DropDown.Visible) 447LayoutTransaction.DoLayout(DropDown, this, PropertyNames.RightToLeft); 451CommonProperties.xClearPreferredSizeCache(DropDown); 452DropDown.LayoutRequired = true; 460if (HasDropDown && DropDown.IsAutoGenerated) 462DropDown.DoLayoutIfHandleCreated(new ToolStripItemEventArgs(this)); 491if (DropDown.OwnerItem != this) 520if (DropDown.OwnerItem != this) 527if (!DropDown.IsAutoGenerated) 529DropDown.OwnerItem = null; 548if (DropDown.OwnerItem == this) 558return DropDown.ProcessCmdKeyInternal(ref m, keyData); 580DropDown.SelectNextToolStripItem(start: null, forward: true); 598DropDown.SelectNextToolStripItem(start: null, forward: true); 713if (DropDown == ParentInternal) 781foreach (ToolStripItem childItem in item.DropDown.Items)
System\Windows\Forms\Controls\ToolStrips\ToolStripDropDownItemAccessibleObject.cs (11)
76if (_owner.DropDown.Visible) 78_owner.DropDown.Close(); 86return _owner.DropDown.Visible ? ExpandCollapseState.ExpandCollapseState_Expanded : ExpandCollapseState.ExpandCollapseState_Collapsed; 97return _owner.DropDown.AccessibilityObject.GetChild(index); 115if (_owner.DropDown.LayoutRequired) 117LayoutTransaction.DoLayout(_owner.DropDown, _owner.DropDown, PropertyNames.Items); 120return _owner.DropDown.AccessibilityObject.GetChildCount(); 166if (_owner.DropDown.AccessibilityObject is ToolStrip.ToolStripAccessibleObject toolStripAccessibleObject) 211return _owner.DropDown.Visible 212? _owner.DropDown.AccessibilityObject
System\Windows\Forms\Controls\ToolStrips\ToolStripItem.cs (1)
3427parent ??= (IsOnOverflow && Owner is not null) ? Owner.OverflowButton.DropDown : Owner;
System\Windows\Forms\Controls\ToolStrips\ToolStripManager.cs (2)
1151tsddownSrc.DropDown.SuspendLayout(); 1168tsddownSrc.DropDown.ResumeLayout();
System\Windows\Forms\Controls\ToolStrips\ToolStripMenuItem.cs (4)
758DropDown.SelectNextToolStripItem(start: null, forward: true); 864showDropDown = !DropDown.Visible; 888ToolStripManager.ModalMenuFilter.CloseActiveDropDown(DropDown, ToolStripDropDownCloseReason.AppClicked); 1054DropDown.SelectNextToolStripItem(start: null, forward: true);
System\Windows\Forms\Controls\ToolStrips\ToolStripOverflowButton.cs (1)
37DropDown.Dispose();
System\Windows\Forms\Controls\ToolStrips\ToolStripOverflowButton.ToolStripOverflowButtonAccessibleObject.cs (2)
28=> _owningToolStripOverflowButton.DropDown.Visible 29? _owningToolStripOverflowButton.DropDown.AccessibilityObject
System\Windows\Forms\Controls\ToolStrips\ToolStripSplitButton.cs (5)
170protected internal override bool DismissWhenClicked => !DropDown.Visible; 181public bool DropDownButtonPressed => DropDown.Visible; 425if (!DropDown.Visible) 452if (DropDown.Visible) 459ToolStripManager.ModalMenuFilter.CloseActiveDropDown(DropDown, ToolStripDropDownCloseReason.AppClicked);
System\Windows\Forms\Controls\ToolStrips\ToolStripSplitButton.ToolStripSplitButtonExAccessibleObject.cs (7)
64if (_owningToolStripSplitButton is not null && _owningToolStripSplitButton.DropDown is not null && _owningToolStripSplitButton.DropDown.Visible) 66_owningToolStripSplitButton.DropDown.Close(); 74return _owningToolStripSplitButton.DropDown.Visible ? ExpandCollapseState.ExpandCollapseState_Expanded : ExpandCollapseState.ExpandCollapseState_Collapsed; 81NavigateDirection.NavigateDirection_FirstChild => DropDownItemsCount > 0 ? _owningToolStripSplitButton.DropDown.Items[0].AccessibilityObject : null, 82NavigateDirection.NavigateDirection_LastChild => DropDownItemsCount > 0 ? _owningToolStripSplitButton.DropDown.Items[_owningToolStripSplitButton.DropDown.Items.Count - 1].AccessibilityObject : null,
System\Windows\Forms\Controls\ToolStrips\ToolStripSplitStackLayout.cs (2)
347item.ParentInternal = (item.Placement == ToolStripItemPlacement.Overflow) ? toolStrip.OverflowButton.DropDown : null; 480item.ParentInternal = (item.Placement == ToolStripItemPlacement.Overflow) ? toolStrip.OverflowButton.DropDown : null;
System\Windows\Forms\MDI\MDIControlStrip.cs (3)
126_system.DropDown.Items.Clear(); 127_system.DropDown.Dispose(); 142_system.DropDown.Dispose();
System\Windows\Forms\MDI\MdiControlStrip.SystemMenuItem.cs (2)
21DropDown.SelectNextToolStripItem(start: null, forward: true); 30if (HasDropDownItems && DropDown.Visible)
System\Windows\Forms\MDI\MdiWindowListStrip.cs (2)
71MergeItem.DropDown.SuspendLayout(); 154MergeItem.DropDown.ResumeLayout(false);
System\Windows\Forms\Printing\PrintPreviewDialog.cs (1)
952if (_zoomToolStripSplitButton.DropDown is ToolStripDropDownMenu menu)
System.Windows.Forms.Design (144)
System\Windows\Forms\Design\BaseContextMenuStrip.cs (3)
122_selectionMenuItem.DropDown.Renderer = (ToolStripProfessionalRenderer)uis.Styles["VsRenderer"]!; 125_selectionMenuItem.DropDown.Font = (Font)uis.Styles["DialogFont"]!; 129_selectionMenuItem.DropDown.ForeColor = color;
System\Windows\Forms\Design\StandardMenuStripVerb.cs (2)
189rootItem.DropDown.SuspendLayout(); 207rootItem.DropDown.ResumeLayout(false);
System\Windows\Forms\Design\ToolStripCollectionEditor.ToolStripItemEditorForm.cs (1)
961currentToolStrip = instance is ToolStripDropDownItem toolStripDropDownItem ? toolStripDropDownItem.DropDown : instance as ToolStrip;
System\Windows\Forms\Design\ToolStripContainerDesigner.cs (1)
298Rectangle controlBounds = BehaviorService?.ControlRectInAdornerWindow(dropDownItem.DropDown) ?? Rectangle.Empty;
System\Windows\Forms\Design\ToolStripDesigner.cs (19)
711if (ToolStrip.CanOverflow && !ToolStrip.OverflowButton.DropDown.Visible) 722if (ToolStrip.OverflowButton.DropDown.Visible) 838ToolStrip.OverflowButton.DropDown.Closing += OnOverflowDropDownClosing; 842ToolStrip.OverflowButton.DropDown.Resize += OnOverflowDropDownResize; 843ToolStrip.OverflowButton.DropDown.Paint += OnOverFlowDropDownPaint; 990if (ToolStrip.CanOverflow && !ToolStrip.OverflowButton.DropDown.Visible) 1086_boundsToInvalidate = dropDownItem.DropDown.Bounds; 1162ToolStrip.OverflowButton.DropDown.Closing -= OnOverflowDropDownClosing; 1166ToolStrip.OverflowButton.DropDown.Resize -= OnOverflowDropDownResize; 1167ToolStrip.OverflowButton.DropDown.Paint -= OnOverFlowDropDownPaint; 1188if (ToolStrip.OverflowButton.DropDown.Visible) 1442ToolStrip.OverflowButton.DropDown.TopLevel = false; 2013_toolStripAdornerWindowService.Invalidate(ddi.DropDown.Bounds); 2050ToolStripItem nextItem = ddi.DropDown.GetNextItem(null, ArrowDirection.Down); 2088if (ddi.DropDown.TopLevel) 2090ddi.DropDown.TopLevel = false; 2096ddi.DropDown.Parent = _toolStripAdornerWindowService.ToolStripAdornerWindowControl; 2326if (ToolStrip.OverflowButton.DropDown.Visible) 2356if (!DontCloseOverflow && ToolStrip.OverflowButton.DropDown.Visible)
System\Windows\Forms\Design\ToolStripDesignerUtils.cs (1)
98parent = ((ToolStripDropDownItem)stripItem).DropDown;
System\Windows\Forms\Design\ToolStripDropDownDesigner.cs (4)
297_menuItem.DropDown.AutoClose = true; 432topmost = _menuItem.DropDown; 456topmost = _menuItem.DropDown; 657_menuItem.DropDown.OwnerItem = _menuItem;
System\Windows\Forms\Design\ToolStripDropDownItemDesigner.cs (1)
28if (Component is ToolStripDropDownItem item && item.DropDown.IsAutoGenerated)
System\Windows\Forms\Design\ToolStripItemCustomMenuItemCollection.cs (8)
81item.DropDown.Renderer = (ToolStripProfessionalRenderer)uis.Styles["VsRenderer"]; 82item.DropDown.Font = (Font)uis.Styles["DialogFont"]; 169_alignmentToolStripMenuItem.DropDown.Renderer = renderer; 170_displayStyleToolStripMenuItem.DropDown.Renderer = renderer; 173_alignmentToolStripMenuItem.DropDown.Font = font; 174_displayStyleToolStripMenuItem.DropDown.Font = font; 180_alignmentToolStripMenuItem.DropDown.ForeColor = panelTextColor; 181_displayStyleToolStripMenuItem.DropDown.ForeColor = panelTextColor;
System\Windows\Forms\Design\ToolStripItemDesigner.cs (1)
176if (strip.OverflowButton.DropDown.Visible)
System\Windows\Forms\Design\ToolStripKeyboardHandlingService.cs (8)
529if (Host.GetDesigner(parentItem.DropDown) is ToolStripDropDownDesigner dropDownDesigner) 533else if (!parentItem.DropDown.Visible && Host.GetDesigner(parentItem) is ToolStripMenuItemDesigner designer) 649if (selSvc.PrimarySelection is ToolStripDropDownItem dropDownItem && dropDownItem.DropDown.Visible) 1241targetSelection = GetNextItem(dropDownItem.DropDown, null, ArrowDirection.Right); 1248if (!dropDownItem.DropDown.Visible 1359parentToMoveOn = dropDownItem.DropDown; 1365? dropDownItem.Owner.OverflowButton.DropDown 2052object newSelection = GetNextItem(overFlowButton.DropDown, null, ArrowDirection.Down);
System\Windows\Forms\Design\ToolStripMenuItemDesigner.cs (92)
87if (MenuItem.DropDown.IsAutoGenerated) 130if (MenuItem.DropDown is not null) 135if (MenuItem.DropDown.IsAutoGenerated && MenuItem.DropDownItems.Count > 0) 191MenuItem.DropDown.OwnerItem = MenuItem; 192MenuItem.DropDown.Disposed += OnDropDownDisposed; 305&& MenuItem.DropDown == selectedItem) 436MenuItem.DropDown.SuspendLayout(); 445MenuItem.DropDown.Items.Remove(_commitedEditorNode); 575MenuItem.DropDown.ResumeLayout(true); 576MenuItem.DropDown.PerformLayout(); 624MenuItem.DropDown.SuspendLayout(); 629MenuItem.DropDown.Items.Remove(_commitedEditorNode); 665MenuItem.DropDown.ResumeLayout(); 699MenuItem.DropDown.PerformLayout(); 711AddNewTemplateNode(MenuItem.DropDown); 713if (MenuItem.DropDown.Site is null) 715MenuItem.DropDown.Text = $"{MenuItem.Name}.DropDown"; 720MenuItem.DropDown.Items.Add(_typeHereNode); 725MenuItem.DropDown.PerformLayout(); 974MenuItem.DropDown.Hide(); 1082ddi.DropDown.TopLevel = false; 1083ddi.DropDown.Parent = _toolStripAdornerWindowService.ToolStripAdornerWindowControl; 1098Control rootControl = ddi.DropDown; 1130if (ddi.DropDown.Site is not null || ddi.DropDownItems.Count == 1) 1137_toolStripAdornerWindowService?.Invalidate(ddi.DropDown.Bounds); 1242MenuItem.DropDown.SuspendLayout(); 1271MenuItem.DropDown.ResumeLayout(); 1310MenuItem.DropDown.SuspendLayout(); 1335MenuItem.DropDown.ResumeLayout(); 1343dropDownItem.DropDown.Location = new Point(dropDownItem.DropDown.Location.X + _commitedEditorNode.Bounds.Width - dropDownItem.Bounds.Width, dropDownItem.DropDown.Location.Y); 1400if (item.DropDown.Visible) 1455MenuItem.DropDown.Closing += OnDropDownClosing; 1459MenuItem.DropDown.Resize += DropDownResize; 1460MenuItem.DropDown.ItemAdded += OnItemAdded; 1461MenuItem.DropDown.Paint += DropDownPaint; 1462MenuItem.DropDown.Click += DropDownClick; 1463MenuItem.DropDown.LocationChanged += DropDownLocationChanged; 1543if (MenuItem.DropDown.OwnerItem is ToolStripDropDownItem currentOwner && currentOwner != MenuItem) 1554if (MenuItem.DropDown.Site is not null) 1556if (_designerHost.GetDesigner(MenuItem.DropDown) is ToolStripDropDownDesigner designer) 1563MenuItem.DropDown.TopLevel = false; 1566MenuItem.DropDown.AllowDrop = true; 1568MenuItem.DropDown.AutoClose = false; 1621Rectangle itemDropDownBounds = MenuItem.DropDown.Bounds; 1646if (IsOnContextMenu && MenuItem.DropDown.Site is not null) 1650MemberDescriptor member = TypeDescriptor.GetProperties(MenuItem.DropDown)["Items"]; 1651changeService.OnComponentChanging(MenuItem.DropDown, member); 1665if (IsOnContextMenu && MenuItem.DropDown.Site is not null) 1667MenuItem.DropDown.Items.Insert(_indexToInsertNewItem, newItem); 1683if (IsOnContextMenu && MenuItem.DropDown.Site is not null) 1685MenuItem.DropDown.Items.Insert(index + 1, newItem); 1694if (IsOnContextMenu && MenuItem.DropDown.Site is not null) 1696MenuItem.DropDown.Items.Insert(index, newItem); 1711if (IsOnContextMenu && MenuItem.DropDown.Site is not null) 1713MenuItem.DropDown.Items.Insert(count - 1, newItem); 1723if (IsOnContextMenu && MenuItem.DropDown.Site is not null) 1725MenuItem.DropDown.Items.Add(newItem); 1749if (IsOnContextMenu && MenuItem.DropDown.Site is not null) 1753MemberDescriptor member = TypeDescriptor.GetProperties(MenuItem.DropDown)["Items"]; 1754changeService.OnComponentChanged(MenuItem.DropDown, member); 1885regionToInvalidate.Exclude(MenuItem.DropDown.Bounds); 1934_boundsToInvalidateOnRemove = ownerItem.DropDown.Bounds; 1938_boundsToInvalidateOnRemove = Rectangle.Union(_boundsToInvalidateOnRemove, dropDownItem.DropDown.Bounds); 1974MenuItem.DropDown?.Disposed -= OnDropDownDisposed; 1991int currentIndexOfEditor = MenuItem.DropDown.Items.IndexOf(_typeHereNode); 1992if (currentIndexOfEditor >= 0 && currentIndexOfEditor < MenuItem.DropDown.Items.Count - 1) 1995MenuItem.DropDown.ItemAdded -= OnItemAdded; 1996MenuItem.DropDown.SuspendLayout(); 1997MenuItem.DropDown.Items.Remove(_typeHereNode); 1998MenuItem.DropDown.Items.Add(_typeHereNode); 1999MenuItem.DropDown.ResumeLayout(); 2000MenuItem.DropDown.ItemAdded += OnItemAdded; 2018if (_dropDownSet && MenuItem.DropDown.IsAutoGenerated) 2038MenuItem.DropDown.PerformLayout(); 2062if (!IsOnContextMenu && MenuItem.DropDown.Visible) 2066if (!MenuItem.DropDown.IsAutoGenerated) 2182if (MenuItem.DropDown.Visible) 2187if (selectedObj is ToolStripDropDown selectedDropDown && MenuItem.DropDown == selectedDropDown) 2199if (parent == MenuItem.DropDown) 2212if (MenuItem.DropDown.OwnerItem == MenuItem) 2274Rectangle bounds = ownerItem.DropDown.Bounds; 2305MenuItem.DropDown.Items.Remove(_commitedEditorNode); 2367if (item.DropDown.Visible) 2511if (currentSelection is not null && !currentSelection.DropDown.Visible) 2531MenuItem.DropDown.Closing -= OnDropDownClosing; 2535MenuItem.DropDown.Resize -= DropDownResize; 2536MenuItem.DropDown.ItemAdded -= OnItemAdded; 2537MenuItem.DropDown.Paint -= DropDownPaint; 2538MenuItem.DropDown.LocationChanged -= DropDownLocationChanged; 2539MenuItem.DropDown.Click -= DropDownClick;
System\Windows\Forms\Design\ToolStripTemplateNode.cs (3)
386_addItemButton?.DropDown.Visible = false; 680_addItemButton.DropDown.Dispose(); 967_addItemButton.DropDown.Focus();