1 implementation of GetDesigner
System.Windows.Forms.Design (1)
System\ComponentModel\Design\DesignerHost.cs (1)
1032
IDesigner? IDesignerHost.
GetDesigner
(IComponent component)
254 references to GetDesigner
DesignSurfaceExt (1)
DesignSurfaceExt.cs (1)
214
|| host.
GetDesigner
(newComp) is not IDesigner designer)
System.ComponentModel.TypeConverter (1)
System\ComponentModel\TypeDescriptor.cs (1)
655
object? designer = host.
GetDesigner
(component);
System.Windows.Forms (1)
System\Windows\Forms\Controls\PropertyGrid\PropertyGrid.cs (1)
1770
IDesigner? designer = designerHost.
GetDesigner
(component);
System.Windows.Forms.Design (204)
System\ComponentModel\Design\CollectionEditor.cs (1)
100
if (host.
GetDesigner
(instance) is IComponentInitializer initializer)
System\ComponentModel\Design\ComponentDesigner.cs (2)
202
IDesigner? designer = host.
GetDesigner
(comp);
227
return host.
GetDesigner
(parent);
System\ComponentModel\Design\DesignerActionPanel.cs (1)
622
if (host?.
GetDesigner
(relatedComponent) is ComponentDesigner componentDesigner)
System\ComponentModel\Design\DesignerHost.cs (1)
1100
IRootDesigner rootDesigner = (((IDesignerHost)this).
GetDesigner
(_rootComponent!) as IRootDesigner)
System\ComponentModel\Design\DesignSurface.cs (1)
156
if (((IDesignerHost)_host).
GetDesigner
(rootComponent) is not IRootDesigner rootDesigner)
System\ComponentModel\Design\MenuCommandService.cs (1)
205
IDesigner? designer = designerHost.
GetDesigner
(selectedComponent);
System\ComponentModel\Design\ToolStripContainerActionList.cs (1)
49
ToolStripPanelDesigner? panelDesigner = _designerHost.
GetDesigner
(component) as ToolStripPanelDesigner;
System\ComponentModel\Design\TypeDescriptorFilterService.cs (1)
29
return host.
GetDesigner
(component);
System\Drawing\Design\ToolboxItem.cs (1)
286
if (host.
GetDesigner
(components[i]) is IComponentInitializer init)
System\Windows\Forms\Design\BaseContextMenuStrip.cs (1)
108
if (host.
GetDesigner
(selectedItem) is ToolStripItemDesigner itemDesigner)
System\Windows\Forms\Design\Behavior\BehaviorService.cs (1)
803
if (host.
GetDesigner
(comp) is ControlDesigner designer)
System\Windows\Forms\Design\Behavior\ContainerSelectorBehavior.cs (1)
228
if (host.
GetDesigner
(ctrl) is ControlDesigner des && (des.SelectionRules & SelectionRules.Moveable) != 0)
System\Windows\Forms\Design\Behavior\DragAssistanceManager.cs (3)
489
if (host.
GetDesigner
(c) is ControlDesigner controlDesigner)
558
if (host.
GetDesigner
(targetControl) is not ControlDesigner controlDesigner)
593
if (host.
GetDesigner
(comp) is ControlDesigner designer)
System\Windows\Forms\Design\Behavior\DropSourceBehavior.cs (1)
657
if (newDestHost.
GetDesigner
(target) is ControlDesigner designer && !designer.ParticipatesWithSnapLines)
System\Windows\Forms\Design\Behavior\ResizeBehavior.cs (1)
218
if (designerHost.
GetDesigner
(_resizeComponents[i].resizeControl) is ControlDesigner designer)
System\Windows\Forms\Design\Behavior\SelectionManager.cs (1)
248
IDesigner? designer = _designerHost.
GetDesigner
(component);
System\Windows\Forms\Design\Behavior\ToolStripPanelSelectionBehavior.cs (1)
275
host.
GetDesigner
(_relatedControl) is ToolStripPanelDesigner toolStripPanelDesigner
System\Windows\Forms\Design\ChangeToolStripParentVerb.cs (1)
42
if (_host.
GetDesigner
(root) is ParentControlDesigner rootDesigner)
System\Windows\Forms\Design\CommandSet.cs (18)
461
if (host.
GetDesigner
(comp) is ControlDesigner des && (des.SelectionRules & selectionRules) == selectionRules)
517
if (host.
GetDesigner
(component) is not ComponentDesigner designer)
719
IDesigner? designer = host.
GetDesigner
(pri);
860
if (host.
GetDesigner
(primaryControl.Parent!) is ParentControlDesigner parentDesigner)
917
if (host.
GetDesigner
(component) is ControlDesigner des && ((des.SelectionRules & rules) != rules))
1001
if (host?.
GetDesigner
(comp) is not ControlDesigner)
1171
if (host is not null && host.
GetDesigner
(comp) is not ControlDesigner)
1497
&& host.
GetDesigner
(parent) is ParentControlDesigner designer
1621
if (host.
GetDesigner
(parent) is ParentControlDesigner designer
1657
if (host.
GetDesigner
((IComponent)obj) is ITreeDesigner designer)
1697
if (host.
GetDesigner
(c) is ITreeDesigner designer && host.
GetDesigner
(commonParent) is ITreeDesigner commonParentDesigner && designer.Parent != commonParentDesigner)
1770
if (host.
GetDesigner
(commonParent) is ITreeDesigner { Children: not null } commonParentDesigner)
1918
ITreeDesigner? tree = host.
GetDesigner
(selectedComponent) as ITreeDesigner;
2008
if (host.
GetDesigner
(curComp) is not ComponentDesigner cDesigner)
2033
if (host.
GetDesigner
(parentComp) is ParentControlDesigner parentDesigner && !designerList.Contains(parentDesigner))
2108
IDesigner? des = host.
GetDesigner
(c);
3081
&& host.
GetDesigner
(primarySelection) is ParentControlDesigner)
System\Windows\Forms\Design\ComponentTray.cs (4)
281
if (selObj is IComponent selectedComponent && !(host.
GetDesigner
(selectedComponent) is ControlDesigner))
1079
IDesigner designer = host.
GetDesigner
(host.RootComponent);
1698
if (host.
GetDesigner
(host.RootComponent) is IRootDesigner rd)
2099
IDesigner designer = host.
GetDesigner
(_component);
System\Windows\Forms\Design\ControlCodeDomSerializer.cs (1)
197
ControlDesigner? controlDesigner = host?.
GetDesigner
(control) as ControlDesigner;
System\Windows\Forms\Design\ControlCommandSet.cs (6)
526
ControlDesigner des = host.
GetDesigner
(comp) as ControlDesigner;
694
ParentControlDesigner parentDesigner = host.
GetDesigner
(primaryControl.Parent) as ParentControlDesigner;
755
des = host.
GetDesigner
(component) as ControlDesigner;
1201
ComponentDesigner baseDesigner = host.
GetDesigner
(_baseControl) as ComponentDesigner;
1479
ControlDesigner controlDesigner = host.
GetDesigner
(selection) as ControlDesigner;
1489
controlDesigner = host.
GetDesigner
(selection) as ControlDesigner;
System\Windows\Forms\Design\ControlDesigner.ControlDesignerAccessibleObject.cs (1)
88
if (DesignerHost.
GetDesigner
(owner) is ControlDesigner ctlDesigner)
System\Windows\Forms\Design\ControlDesigner.cs (8)
495
if (e.Control is null || _host is null || _host.
GetDesigner
(e.Control) is ControlDesigner)
864
if (child is null || _host is null || _host.
GetDesigner
(child) is ControlDesigner)
1151
if (host.
GetDesigner
(parent) is ParentControlDesigner parentDesigner)
1427
if (_host?.
GetDesigner
(comp) is ControlDesigner des && (des.SelectionRules & SelectionRules.Moveable) != 0)
1462
object? designer = _host?.
GetDesigner
(parent);
1491
object? designer = _host?.
GetDesigner
(parent);
1520
object? designer = _host?.
GetDesigner
(parent);
2172
if (_host is not null && _host.RootComponent is not null && _host.
GetDesigner
(_host.RootComponent) is IRootDesigner rd)
System\Windows\Forms\Design\DesignBindingPicker.cs (1)
489
BindingSourceDesigner? designer = _designerHost.
GetDesigner
(instance) as BindingSourceDesigner;
System\Windows\Forms\Design\DesignerUtils.cs (1)
804
if (host?.
GetDesigner
(component) is not ComponentDesigner designer)
System\Windows\Forms\Design\DocumentDesigner.cs (3)
631
ParentControlDesigner designer = host.
GetDesigner
(c) as ParentControlDesigner;
891
IDesigner designer = host.
GetDesigner
(component);
992
ComponentDesigner compDesigner = host.
GetDesigner
(selComp) as ComponentDesigner;
System\Windows\Forms\Design\OleDragDropHandler.CfCodeToolboxItem.cs (1)
95
if (defaultValues["Parent"] is Control parentControl && host.
GetDesigner
(parentControl) is ParentControlDesigner parentControlDesigner)
System\Windows\Forms\Design\OleDragDropHandler.ComponentDataObject.cs (1)
119
if (host.
GetDesigner
(component) is not ComponentDesigner designer)
System\Windows\Forms\Design\ParentControlDesigner.cs (13)
194
ParentControlDesigner designer = host.
GetDesigner
(child) as ParentControlDesigner;
272
ParentControlDesigner designer = host.
GetDesigner
(child) as ParentControlDesigner;
410
ParentControlDesigner designer = host.
GetDesigner
(child) as ParentControlDesigner;
456
&& host.
GetDesigner
(newChild) as ControlDesigner is not null && !(newChild is Form form && form.TopLevel))
662
IComponentInitializer init = host.
GetDesigner
(component) as IComponentInitializer;
899
ControlDesigner cd = host.
GetDesigner
(comp) as ControlDesigner;
1079
return (host.
GetDesigner
(parent) as ParentControlDesigner);
1253
if (host.
GetDesigner
(parent) is not ParentControlDesigner parentDesigner)
1494
DocumentDesigner parentDesigner = host.
GetDesigner
(host.RootComponent) as DocumentDesigner;
1534
object draggedDesigner = host.
GetDesigner
(comp);
1677
if (host?.
GetDesigner
(host.RootComponent) is DocumentDesigner parentDesigner)
2445
IComponentInitializer init = localDesignerHost.
GetDesigner
(component) as IComponentInitializer;
2477
IDesigner designer = host.
GetDesigner
(component);
System\Windows\Forms\Design\SelectionUIService.SelectionUIItem.cs (1)
83
if (selUIsvc._host.
GetDesigner
(comp) is ControlDesigner cd)
System\Windows\Forms\Design\SplitContainerDesigner.cs (6)
105
return _designerHost?.
GetDesigner
(panel) as ControlDesigner;
119
if (_designerHost!.
GetDesigner
(_selectedPanel) is SplitterPanelDesigner panelDesigner1)
130
if (_designerHost!.
GetDesigner
(value) is SplitterPanelDesigner panelDesigner)
164
var selectedPanelDesigner = (SplitterPanelDesigner)_designerHost!.
GetDesigner
(Selected)!;
201
var panelDesigner = _designerHost?.
GetDesigner
(_splitterPanel1!) as SplitterPanelDesigner;
212
panelDesigner = _designerHost?.
GetDesigner
(_splitterPanel2!) as SplitterPanelDesigner;
System\Windows\Forms\Design\SplitterPanelDesigner.cs (1)
111
_splitContainerDesigner = (SplitContainerDesigner?)_designerHost?.
GetDesigner
(_splitterPanel.Parent!);
System\Windows\Forms\Design\StandardMenuStripVerb.cs (4)
138
IDesigner designer = _host.
GetDesigner
(item);
150
IDesigner designer = _host.
GetDesigner
(item);
309
IDesigner designer = _host.
GetDesigner
(item);
319
IDesigner designer = _host.
GetDesigner
(item);
System\Windows\Forms\Design\StyleEditorForm.cs (1)
105
_tableLayoutPanelDesigner = host.
GetDesigner
(_tableLayoutPanel) as TableLayoutPanelDesigner;
System\Windows\Forms\Design\TabControlDesigner.cs (2)
134
TabPageDesigner selectedTabPageDesigner = host.
GetDesigner
(tc.SelectedTab) as TabPageDesigner;
491
pageDesigner = host.
GetDesigner
(selectedTab) as TabPageDesigner;
System\Windows\Forms\Design\TemplateNodeCustomMenuItemCollection.cs (2)
76
IDesigner designer = designerHost.
GetDesigner
(component);
140
if (designerHost.
GetDesigner
(ownerItem) is ToolStripMenuItemDesigner itemDesigner)
System\Windows\Forms\Design\ToolStripContainerDesigner.cs (4)
140
return _designerHost.
GetDesigner
(panel) as ControlDesigner;
199
private ToolStripPanelDesigner? GetDesigner(ToolStripPanel panel) => _designerHost.
GetDesigner
(panel) as ToolStripPanelDesigner;
201
private PanelDesigner? GetDesigner(ToolStripContentPanel panel) => _designerHost.
GetDesigner
(panel) as PanelDesigner;
394
ToolStripPanelDesigner? panelDesigner = _designerHost?.
GetDesigner
(_topToolStripPanel) as ToolStripPanelDesigner;
System\Windows\Forms\Design\ToolStripDesigner.cs (17)
489
ToolStripItemDesigner dropDownItemDesigner = (ToolStripItemDesigner)_host.
GetDesigner
(item);
524
designer = _host.
GetDesigner
(component) as ToolStripItemDesigner;
575
ToolStripItemDesigner designer = _host.
GetDesigner
(component) as ToolStripItemDesigner;
828
if (_host.
GetDesigner
(selectedItem) is ToolStripMenuItemDesigner itemDesigner && itemDesigner.IsEditorActive)
844
if (_host.
GetDesigner
(ownerItem) is ToolStripMenuItemDesigner itemDesigner && itemDesigner.IsEditorActive)
856
ToolStripItemDesigner itemDesigner = (ToolStripItemDesigner)_host.
GetDesigner
(toolItem);
1243
IDesigner itemDesigner = _host.
GetDesigner
(selectedItem);
1282
ToolStripItemDesigner itemDesigner = (ToolStripItemDesigner)_host.
GetDesigner
(toolItem);
1305
ToolStripItemDesigner itemDesigner = (ToolStripItemDesigner)_host.
GetDesigner
(item);
1359
ToolStripItemDesigner itemDesigner = (ToolStripItemDesigner)_host.
GetDesigner
(item);
1478
parentFormDesigner = _host.
GetDesigner
(parentForm) as FormDocumentDesigner;
1911
if (_host.
GetDesigner
(primaryDropDownItem) is ToolStripMenuItemDesigner dropDownItemDesigner)
2054
&& _host.
GetDesigner
(item) is ToolStripItemDesigner designer)
2137
if (_host.
GetDesigner
(selectedItem) is ToolStripMenuItemDesigner selectedItemDesigner)
2238
ToolStripItemDesigner dropDownItemDesigner = (ToolStripItemDesigner)_host.
GetDesigner
(item);
2432
if (_host.
GetDesigner
(newItem) is ToolStripItemDesigner newItemDesigner)
2470
ToolStripItemDesigner itemDesigner = (ToolStripItemDesigner)_host.
GetDesigner
(item);
System\Windows\Forms\Design\ToolStripDesignerUtils.cs (2)
453
designer = designerHost.
GetDesigner
(selItem) as ToolStripItemDesigner;
491
designer = designerHost.
GetDesigner
(nextSelection) as ToolStripItemDesigner;
System\Windows\Forms\Design\ToolStripDropDownDesigner.cs (7)
148
ToolStripMenuItemDesigner itemDesigner = (ToolStripMenuItemDesigner)_host.
GetDesigner
(_menuItem);
207
ToolStripItemDesigner itemDesigner = (ToolStripItemDesigner)_host.
GetDesigner
(item);
336
if (_host.
GetDesigner
(_menuItem) is ToolStripMenuItemDesigner itemDesigner)
445
ToolStripMenuItemDesigner itemDesigner = (ToolStripMenuItemDesigner)_host.
GetDesigner
(comp);
469
ToolStripMenuItemDesigner itemDesigner = (ToolStripMenuItemDesigner)_host.
GetDesigner
(ownerItem);
658
if (_host.
GetDesigner
(_currentParent) is ToolStripMenuItemDesigner ownerItemDesigner)
680
ToolStripMenuItemDesigner itemDesigner = (ToolStripMenuItemDesigner)_host.
GetDesigner
(_menuItem);
System\Windows\Forms\Design\ToolStripEditorManager.cs (1)
77
_itemDesigner = (ToolStripItemDesigner)_designerHost.
GetDesigner
(_currentItem);
System\Windows\Forms\Design\ToolStripInSituService.cs (6)
107
_toolItemDesigner = host.
GetDesigner
(parentItem) as ToolStripMenuItemDesigner;
120
_toolDesigner = host.
GetDesigner
(tool) as ToolStripDesigner;
131
if (host.
GetDesigner
(comp) is ToolStripDropDownDesigner designer)
136
_toolItemDesigner = host.
GetDesigner
(toolItem) as ToolStripItemDesigner;
147
_toolDesigner = host.
GetDesigner
(comp) as ToolStripDesigner;
156
_toolItemDesigner = host.
GetDesigner
(comp) as ToolStripItemDesigner;
System\Windows\Forms\Design\ToolStripItemBehavior.cs (9)
156
if (designerHost.
GetDesigner
(item) is ToolStripItemDesigner itemDesigner)
553
if (designerHost.
GetDesigner
(parentToolStrip) is ToolStripDesigner parentDesigner)
564
if (designerHost.
GetDesigner
(ownerItem) is ToolStripItemDesigner ownerItemDesigner)
606
if (designerHost.
GetDesigner
(ddItem) is ToolStripMenuItemDesigner itemDesigner)
795
if (designerHost.
GetDesigner
(item) is ToolStripMenuItemDesigner itemDesigner)
805
if (designerHost.
GetDesigner
(ownerItem) is ToolStripMenuItemDesigner ownerDesigner)
981
ToolStripItemDesigner itemDesigner = designerHost.
GetDesigner
(glyphItem) as ToolStripItemDesigner;
983
if (designerHost.
GetDesigner
(parentToolStrip) is ToolStripDesigner parentDesigner)
1006
if (designerHost.
GetDesigner
(ownerItem) is ToolStripItemDesigner ownerItemDesigner)
System\Windows\Forms\Design\ToolStripItemCustomMenuItemCollection.cs (8)
210
if (_designerHost.
GetDesigner
(_currentItem) is ToolStripItemDesigner itemDesigner)
236
if (_designerHost.
GetDesigner
(_currentItem) is ToolStripItemDesigner itemDesigner)
305
ToolStripItemDesigner _designer = (ToolStripItemDesigner)_designerHost.
GetDesigner
(_currentItem);
391
IDesigner designer = designerHost.
GetDesigner
(component);
409
if (designerHost.
GetDesigner
(parent.OwnerItem.Owner) is ToolStripDesigner toolStripDesigner)
442
IDesigner designer = designerHost.
GetDesigner
(component);
481
IDesigner designer = designerHost.
GetDesigner
(component);
521
IDesigner designer = designerHost.
GetDesigner
(component);
System\Windows\Forms\Design\ToolStripItemDesigner.cs (6)
334
ToolStripDesigner designer = (ToolStripDesigner)designerHost.
GetDesigner
(ToolStripItem.Owner);
431
ToolStripItemDesigner itemDesigner = (ToolStripItemDesigner)designerHost.
GetDesigner
(newItem);
745
ownerItemDesigner = (ToolStripMenuItemDesigner)host.
GetDesigner
(ownerItem);
993
ToolStripMenuItemDesigner parentItemDesigner = (ToolStripMenuItemDesigner)designerHost.
GetDesigner
(parentItem);
1001
ToolStripDropDownDesigner parentDropDownDesigner = (ToolStripDropDownDesigner)designerHost.
GetDesigner
(parentDropDown);
1221
ToolStripDesigner parentDesigner = (ToolStripDesigner)designerHost.
GetDesigner
(parent);
System\Windows\Forms\Design\ToolStripKeyboardHandlingService.cs (17)
532
if (Host.
GetDesigner
(parentItem.DropDown) is ToolStripDropDownDesigner dropDownDesigner)
536
else if (!parentItem.DropDown.Visible && Host.
GetDesigner
(parentItem) is ToolStripMenuItemDesigner designer)
627
if (host.
GetDesigner
(item) is ToolStripItemDesigner)
632
if (host.
GetDesigner
(dropDown) is ToolStripDropDownDesigner dropDownDesigner)
644
if (host.
GetDesigner
(ownerItem) is ToolStripMenuItemDesigner itemDesigner)
656
if (host.
GetDesigner
(dropDownItem) is ToolStripMenuItemDesigner selectedItemDesigner)
851
if (host.
GetDesigner
(ownerItem) is ToolStripMenuItemDesigner itemDesigner)
865
if (host.
GetDesigner
(typeHereNode.Owner) is ToolStripDesigner tooldesigner)
881
IDesigner designer = host.
GetDesigner
(pri);
931
if (host.
GetDesigner
(comp) is ToolStripMenuItemDesigner designer)
946
if (host.
GetDesigner
(ownerItem) is ToolStripMenuItemDesigner itemDesigner)
956
if (host.
GetDesigner
(typeHereNode.Owner) is ToolStripDesigner tooldesigner)
1261
&& host.
GetDesigner
(dropDownItem) is ToolStripMenuItemDesigner designer)
1801
ControlDesigner controlDesigner = host.
GetDesigner
((IComponent)targetSelection) as ControlDesigner;
1810
controlDesigner = targetSelection is not null ? host.
GetDesigner
((IComponent)targetSelection) as ControlDesigner : null;
1898
ControlDesigner controlDesigner = host.
GetDesigner
((IComponent)targetSelection) as ControlDesigner;
1907
controlDesigner = targetSelection is not null ? host.
GetDesigner
((IComponent)targetSelection) as ControlDesigner : null;
System\Windows\Forms\Design\ToolStripMenuItemDesigner.cs (26)
282
if (_designerHost.
GetDesigner
(toolItem) is ToolStripItemDesigner designer)
389
ToolStripItemDesigner dropDownItemDesigner = (ToolStripItemDesigner)_designerHost.
GetDesigner
(item);
409
ToolStripMenuItemDesigner itemDesigner = (ToolStripMenuItemDesigner)_designerHost.
GetDesigner
(item);
457
if (_designerHost.
GetDesigner
(editedItem) is ToolStripItemDesigner itemDesigner)
801
ToolStripItemDesigner designer = _designerHost.
GetDesigner
(newItem) as ToolStripItemDesigner;
873
ToolStripItemDesigner designer = _designerHost.
GetDesigner
(newItem) as ToolStripItemDesigner;
971
ToolStripMenuItemDesigner itemDesigner = (ToolStripMenuItemDesigner)_designerHost.
GetDesigner
(currentItem);
1072
if (_designerHost.
GetDesigner
(item) is ToolStripItemDesigner designer)
1131
if (_designerHost.
GetDesigner
(_designerHost.RootComponent) is ControlDesigner designer)
1199
if (_designerHost.
GetDesigner
(_designerHost.RootComponent) is ControlDesigner designer)
1307
if (_designerHost.
GetDesigner
(newDummyItem) is ToolStripMenuItemDesigner newItemDesigner)
1327
IDesigner designer = _designerHost.
GetDesigner
(ownerItem);
1578
if (_designerHost.
GetDesigner
(currentOwner) is ToolStripMenuItemDesigner ownerdesigner)
1589
if (_designerHost.
GetDesigner
(MenuItem.DropDown) is ToolStripDropDownDesigner designer)
1805
if (_designerHost.
GetDesigner
(mainStrip) is ToolStripDesigner mainStripDesigner && mainStripDesigner.InsertTransaction is not null)
1853
if (_designerHost.
GetDesigner
(mainStrip) is ToolStripDesigner mainStripDesigner && !mainStripDesigner.EditingCollection && mainStripDesigner.InsertTransaction is null)
2063
if (_designerHost.
GetDesigner
(mainStrip) is ToolStripDesigner mainStripDesigner && mainStripDesigner.CacheItems)
2112
if (_designerHost.
GetDesigner
(mainStrip) is ToolStripDesigner mainStripDesigner)
2163
if (_designerHost.
GetDesigner
(firstDropDown) is ToolStripDropDownDesigner firstDropDownDesigner)
2378
ToolStripItemDesigner dropDownItemDesigner = (ToolStripItemDesigner)_designerHost.
GetDesigner
(ddItem);
2399
ToolStripItemDesigner itemDesigner = (ToolStripItemDesigner)_designerHost.
GetDesigner
(item);
2503
IDesigner designer = _designerHost.
GetDesigner
(_parentItem);
2564
if (_designerHost.
GetDesigner
(currentSelection) is ToolStripMenuItemDesigner currentSelectionDesigner)
2572
ToolStripDropDownDesigner dropDownDesigner = (ToolStripDropDownDesigner)_designerHost.
GetDesigner
(currentDropDown);
2764
if (host.
GetDesigner
(dropDownItem) is ToolStripMenuItemDesigner dropDownItemDesigner)
2789
if (host.
GetDesigner
(ownerItem) is ToolStripMenuItemDesigner ownerDesigner)
System\Windows\Forms\Design\ToolStripPanelDesigner.cs (1)
177
&& _designerHost?.
GetDesigner
(contentPanel) is PanelDesigner designer)
System\Windows\Forms\Design\ToolStripTemplateNode.cs (4)
124
_designer = _designerHost.
GetDesigner
(component);
406
ToolStripDesigner designer = _designerHost.
GetDesigner
(_component) as ToolStripDesigner;
567
if (_designerHost.
GetDesigner
(selectedItem) is ToolStripMenuItemDesigner menuItemDesigner)
834
if (_designerHost.
GetDesigner
(curSel) is ToolStripItemDesigner designer)
System.Windows.Forms.Design.Tests (47)
ControlDesignerTests.cs (2)
336
_designer._mockDesignerHost.Setup(h => h.
GetDesigner
(It.IsAny<IComponent>())).Returns(mockParentDesigner.Object);
357
_designer._mockDesignerHost.Setup(h => h.
GetDesigner
(It.IsAny<IComponent>())).Returns(mockParentDesigner.Object);
SplitContainerDesignerTests.cs (1)
20
.Setup(s => s.
GetDesigner
(It.IsAny<Control>()))
System\ComponentModel\Design\CollectionEditorTests.cs (3)
216
.Setup(h => h.
GetDesigner
(result))
263
.Setup(h => h.
GetDesigner
(null))
320
.Setup(h => h.
GetDesigner
(result))
System\ComponentModel\Design\CollectionFormTests.cs (3)
567
.Setup(h => h.
GetDesigner
(result))
615
.Setup(h => h.
GetDesigner
(null))
673
.Setup(h => h.
GetDesigner
(result))
System\ComponentModel\Design\ComponentDesignerTests.cs (16)
110
.Setup(h => h.
GetDesigner
(mockComponent1.Object))
114
.Setup(h => h.
GetDesigner
(mockComponent2.Object))
125
mockDesignerHost.Verify(h => h.
GetDesigner
(mockComponent1.Object), Times.Once());
126
mockDesignerHost.Verify(h => h.
GetDesigner
(mockComponent2.Object), Times.Once());
130
mockDesignerHost.Verify(h => h.
GetDesigner
(mockComponent1.Object), Times.Exactly(2));
131
mockDesignerHost.Verify(h => h.
GetDesigner
(mockComponent2.Object), Times.Exactly(2));
148
.Setup(h => h.
GetDesigner
(mockComponent1.Object))
152
.Setup(h => h.
GetDesigner
(mockComponent2.Object))
163
mockDesignerHost.Verify(h => h.
GetDesigner
(mockComponent1.Object), Times.Once());
164
mockDesignerHost.Verify(h => h.
GetDesigner
(mockComponent2.Object), Times.Once());
168
mockDesignerHost.Verify(h => h.
GetDesigner
(mockComponent1.Object), Times.Exactly(2));
169
mockDesignerHost.Verify(h => h.
GetDesigner
(mockComponent2.Object), Times.Exactly(2));
398
.Setup(h => h.
GetDesigner
(rootComponent))
411
mockDesignerHost.Verify(h => h.
GetDesigner
(rootComponent), Times.Never());
416
mockDesignerHost.Verify(h => h.
GetDesigner
(rootComponent), Times.Exactly(rootComponent is null ? 0 : 1));
422
mockDesignerHost.Verify(h => h.
GetDesigner
(rootComponent), Times.Exactly(rootComponent is null ? 0 : 2));
System\ComponentModel\Design\DesignerHostTests.cs (12)
2254
Assert.IsType<RootDesigner>(host.
GetDesigner
(component));
2255
Assert.Null(host.
GetDesigner
(new Component()));
2256
Assert.Null(host.
GetDesigner
(new RootDesignerComponent()));
2264
Assert.Null(host.
GetDesigner
(new Component()));
2265
Assert.Null(host.
GetDesigner
(new RootDesignerComponent()));
2273
Assert.Throws<ArgumentNullException>("component", () => host.
GetDesigner
(null));
2537
Assert.Null(host.
GetDesigner
(rootComponent));
2538
Assert.NotNull(host.
GetDesigner
(component));
2549
Assert.Null(host.
GetDesigner
(rootComponent));
2550
Assert.NotNull(host.
GetDesigner
(component));
2561
Assert.Null(host.
GetDesigner
(rootComponent));
2562
Assert.Null(host.
GetDesigner
(component));
System\Drawing\Design\ToolboxItemTests.cs (6)
434
.Setup(h => h.
GetDesigner
(component))
500
.Setup(h => h.
GetDesigner
(component))
568
.Setup(h => h.
GetDesigner
(component))
753
.Setup(h => h.
GetDesigner
(component))
819
.Setup(h => h.
GetDesigner
(component))
887
.Setup(h => h.
GetDesigner
(component))
System\Windows\Forms\Design\SplitterPanelDesignerTests.cs (1)
24
mockDesignerHost.Setup(dh => dh.
GetDesigner
(splitterPanel.Parent!)).Returns(splitContainerDesigner);
TestControlDesigner.Mocks.cs (1)
24
.Setup(s => s.
GetDesigner
(It.IsAny<Control>()))
ToolStripMenuItemDesignerTest.cs (2)
104
.Setup(s => s.
GetDesigner
(It.IsAny<Control>()))
133
.Setup(s => s.
GetDesigner
(It.IsAny<Control>()))