110 references to GetService
System.Windows.Forms.Design (109)
System\ComponentModel\Design\ComponentDesigner.cs (2)
385
if (component.Site is IServiceContainer sc &&
GetService
(typeof(DesignerCommandSet)) is null)
560
=>
GetService
(typeof(T)) as T;
System\Windows\Forms\Design\DocumentDesigner.cs (28)
115
IDesignerHost host =
GetService
(typeof(IDesignerHost)) as IDesignerHost;
186
IMenuCommandService menuCommandService = (IMenuCommandService)
GetService
(typeof(IMenuCommandService));
266
IDesignerHost host = (IDesignerHost)
GetService
(typeof(IDesignerHost));
341
IDesignerHost host = (IDesignerHost)
GetService
(typeof(IDesignerHost));
347
ToolStripAdornerWindowService toolWindow = (ToolStripAdornerWindowService)
GetService
(typeof(ToolStripAdornerWindowService));
362
ISplitWindowService sws = (ISplitWindowService)
GetService
(typeof(ISplitWindowService));
373
IComponentChangeService cs = (IComponentChangeService)
GetService
(typeof(IComponentChangeService));
389
IToolboxService toolbox = (IToolboxService)
GetService
(typeof(IToolboxService));
402
ISelectionService ss = (ISelectionService)
GetService
(typeof(ISelectionService));
424
ISplitWindowService sws = (ISplitWindowService)
GetService
(typeof(ISplitWindowService));
464
IPropertyValueUIService pvUISvc = (IPropertyValueUIService)
GetService
(typeof(IPropertyValueUIService));
589
ISelectionService s = (ISelectionService)
GetService
(typeof(ISelectionService));
625
IDesignerHost host = (IDesignerHost)
GetService
(typeof(IDesignerHost));
682
IDesignerHost host = (IDesignerHost)
GetService
(typeof(IDesignerHost));
683
IExtenderProviderService exps = (IExtenderProviderService)
GetService
(typeof(IExtenderProviderService));
718
IComponentChangeService cs = (IComponentChangeService)
GetService
(typeof(IComponentChangeService));
840
if (
GetService
(typeof(IDesignerHost)) is IDesignerHost host)
949
ISplitWindowService sws = (ISplitWindowService)
GetService
(typeof(ISplitWindowService));
953
IDesignerHost host = (IDesignerHost)
GetService
(typeof(IDesignerHost));
969
IMenuCommandService mcs = (IMenuCommandService)
GetService
(typeof(IMenuCommandService));
972
ISelectionService selSvc = (ISelectionService)
GetService
(typeof(ISelectionService));
989
IDesignerHost host = (IDesignerHost)
GetService
(typeof(IDesignerHost));
1075
_undoEngine =
GetService
(typeof(UndoEngine)) as UndoEngine;
1111
ISelectionService ss = (ISelectionService)
GetService
(typeof(ISelectionService));
1179
IHelpService hs = (IHelpService)
GetService
(typeof(IHelpService));
1366
IMenuCommandService mcs = (IMenuCommandService)
GetService
(typeof(IMenuCommandService));
1376
IDesignerHost host = (IDesignerHost)
GetService
(typeof(IDesignerHost));
1387
IToolboxService toolboxService = (IToolboxService)
GetService
(typeof(IToolboxService));
System\Windows\Forms\Design\FlowPanelDesigner.cs (1)
43
SelectionManager? sm =
GetService
(typeof(SelectionManager)) as SelectionManager;
System\Windows\Forms\Design\FormDocumentDesigner.cs (3)
299
IComponentChangeService cs = (IComponentChangeService)
GetService
(typeof(IComponentChangeService));
335
IDesignerHost host = (IDesignerHost)
GetService
(typeof(IDesignerHost));
349
IComponentChangeService cs = (IComponentChangeService)
GetService
(typeof(IComponentChangeService));
System\Windows\Forms\Design\GroupBoxDesigner.cs (1)
89
_inheritanceUI ??= (InheritanceUI)
GetService
(typeof(InheritanceUI));
System\Windows\Forms\Design\ParentControlDesigner.cs (30)
188
IDesignerHost host = (IDesignerHost)
GetService
(typeof(IDesignerHost));
267
IDesignerHost host = (IDesignerHost)
GetService
(typeof(IDesignerHost));
405
IDesignerHost host = (IDesignerHost)
GetService
(typeof(IDesignerHost));
454
IDesignerHost host = (IDesignerHost)
GetService
(typeof(IDesignerHost));
471
ISelectionService selSvc = (ISelectionService)
GetService
(typeof(ISelectionService));
690
IDesignerHost host = (IDesignerHost)
GetService
(typeof(IDesignerHost));
896
IDesignerHost host = (IDesignerHost)
GetService
(typeof(IDesignerHost));
999
IDesignerHost host = (IDesignerHost)
GetService
(typeof(IDesignerHost));
1063
_oleDragDropHandler ??= new OleDragDropHandler(null, (IServiceProvider)
GetService
(typeof(IDesignerHost)), this);
1076
IDesignerHost host = (IDesignerHost)
GetService
(typeof(IDesignerHost));
1209
IDesignerHost host = (IDesignerHost)
GetService
(typeof(IDesignerHost));
1247
if (
GetService
(typeof(IDesignerHost)) is not IDesignerHost host)
1285
IDesignerOptionService optSvc = (IDesignerOptionService)
GetService
(typeof(IDesignerOptionService));
1422
IDesignerHost host = (IDesignerHost)
GetService
(typeof(IDesignerHost));
1465
IMenuCommandService ms = (IMenuCommandService)
GetService
(typeof(IMenuCommandService));
1491
IDesignerHost host = (IDesignerHost)
GetService
(typeof(IDesignerHost));
1578
_toolboxService ??= (IToolboxService)
GetService
(typeof(IToolboxService));
1633
ISelectionService sel = (ISelectionService)
GetService
(typeof(ISelectionService));
1664
IMenuCommandService ms = (IMenuCommandService)
GetService
(typeof(IMenuCommandService));
1676
IDesignerHost host = (IDesignerHost)
GetService
(typeof(IDesignerHost));
1715
_toolboxService ??= (IToolboxService)
GetService
(typeof(IToolboxService));
1719
_mouseDragTool = _toolboxService.GetSelectedToolboxItem((IDesignerHost)
GetService
(typeof(IDesignerHost)));
1732
ISelectionService selsvc = (ISelectionService)
GetService
(typeof(ISelectionService));
1738
IEventHandlerService eventSvc = (IEventHandlerService)
GetService
(typeof(IEventHandlerService));
1813
IEventHandlerService eventSvc = (IEventHandlerService)
GetService
(typeof(IEventHandlerService));
1883
var selSvc = (ISelectionService)
GetService
(typeof(ISelectionService));
2067
_toolboxService ??= (IToolboxService)
GetService
(typeof(IToolboxService));
2313
IDesignerHost localDesignerHost = (IDesignerHost)
GetService
(typeof(IDesignerHost));
2355
IUIService uiSvc = (IUIService)
GetService
(typeof(IUIService));
2473
IDesignerHost host = (IDesignerHost)
GetService
(typeof(IDesignerHost));
System\Windows\Forms\Design\SplitterPanelDesigner.cs (1)
185
var uis =
GetService
(typeof(IUIService)) as IUIService;
System\Windows\Forms\Design\TabControlDesigner.cs (12)
131
IDesignerHost host = (IDesignerHost)
GetService
(typeof(IDesignerHost));
146
ISelectionService svc = (ISelectionService)
GetService
(typeof(ISelectionService));
152
IComponentChangeService cs = (IComponentChangeService)
GetService
(typeof(IComponentChangeService));
217
ISelectionService svc = (ISelectionService)
GetService
(typeof(ISelectionService));
223
IComponentChangeService cs = (IComponentChangeService)
GetService
(typeof(IComponentChangeService));
242
IDesignerHost host = (IDesignerHost)
GetService
(typeof(IDesignerHost));
313
IEventHandlerService eventSvc = (IEventHandlerService)
GetService
(typeof(IEventHandlerService));
337
IDesignerHost host = (IDesignerHost)
GetService
(typeof(IDesignerHost));
400
ISelectionService svc = (ISelectionService)
GetService
(typeof(ISelectionService));
423
SelectionManager selMgr = (SelectionManager)
GetService
(typeof(SelectionManager));
435
ISelectionService svc = (ISelectionService)
GetService
(typeof(ISelectionService));
488
IDesignerHost host = (IDesignerHost)
GetService
(typeof(IDesignerHost));
System\Windows\Forms\Design\TableLayoutPanelDesigner.cs (27)
93
IDesignerHost host =
GetService
(typeof(IDesignerHost)) as IDesignerHost;
197
IDesignerHost host =
GetService
(typeof(IDesignerHost)) as IDesignerHost;
216
_undoEngine =
GetService
(typeof(UndoEngine)) as UndoEngine;
262
DesignerActionUIService actionUIService = (DesignerActionUIService)
GetService
(typeof(DesignerActionUIService));
359
IUIService uis =
GetService
(typeof(IUIService)) as IUIService;
502
IDesignerHost host =
GetService
(typeof(IDesignerHost)) as IDesignerHost;
521
IDesignerHost host =
GetService
(typeof(IDesignerHost)) as IDesignerHost;
549
IDesignerHost host =
GetService
(typeof(IDesignerHost)) as IDesignerHost;
617
ISelectionService selSvc =
GetService
(typeof(ISelectionService)) as ISelectionService;
625
IUIService uiService =
GetService
(typeof(IUIService)) as IUIService;
773
IUIService uiService = (IUIService)
GetService
(typeof(IUIService));
785
IUIService uiService = (IUIService)
GetService
(typeof(IUIService));
799
IDesignerHost host = (IDesignerHost)
GetService
(typeof(IDesignerHost));
1159
IDesignerHost host = (IDesignerHost)
GetService
(typeof(IDesignerHost));
1472
ISelectionService selSvc =
GetService
(typeof(ISelectionService)) as ISelectionService;
1536
IToolboxService tbx = (IToolboxService)
GetService
(typeof(IToolboxService));
1537
if (tbx is not null && tbx.GetSelectedToolboxItem((IDesignerHost)
GetService
(typeof(IDesignerHost))) is not null)
1583
ISelectionService selSvc =
GetService
(typeof(ISelectionService)) as ISelectionService;
1636
IDesignerHost host =
GetService
(typeof(IDesignerHost)) as IDesignerHost;
1703
IUIService uiService = (IUIService)
GetService
(typeof(IUIService));
1751
IDesignerHost host =
GetService
(typeof(IDesignerHost)) as IDesignerHost;
1780
IUIService uiService = (IUIService)
GetService
(typeof(IUIService));
1875
IDesignerHost host =
GetService
(typeof(IDesignerHost)) as IDesignerHost;
1942
IUIService uiService = (IUIService)
GetService
(typeof(IUIService));
1972
IDesignerHost host =
GetService
(typeof(IDesignerHost)) as IDesignerHost;
2037
IUIService uiService = (IUIService)
GetService
(typeof(IUIService));
2056
IUIService uiService = (IUIService)
GetService
(typeof(IUIService));
System\Windows\Forms\Design\ToolStripDesigner.cs (1)
397
if (
GetService
(typeof(DesignerOptionService)) is WindowsFormsDesignerOptionService dos)
System\Windows\Forms\Design\ToolStripDropDownDesigner.cs (3)
350
_host = (IDesignerHost)
GetService
(typeof(IDesignerHost));
353
ToolStripKeyboardHandlingService keyboardHandlingService = (ToolStripKeyboardHandlingService)
GetService
(typeof(ToolStripKeyboardHandlingService));
357
ISupportInSituService inSituService = (ISupportInSituService)
GetService
(typeof(ISupportInSituService));
System.Windows.Forms.Design.Tests (1)
System\ComponentModel\Design\ComponentDesignerTests.cs (1)
2940
public new object GetService(Type serviceType) => base.
GetService
(serviceType);