4 writes to Container
System.Windows.Forms.Design (1)
System\ComponentModel\Design\Serialization\CodeDomComponentSerializationService.CodeDomSerializationStore.cs (1)
205
delegator.Manager.
Container
= container;
System.Windows.Forms.Design.Tests (3)
System\ComponentModel\Design\Serialization\DesignerSerializationManagerTests.cs (3)
88
Container
= value
94
manager.
Container
= value;
104
Assert.Throws<InvalidOperationException>(() => manager.
Container
= null);
19 references to Container
System.Windows.Forms.Design (13)
System\ComponentModel\Design\Serialization\CodeDomComponentSerializationService.CodeDomSerializationStore.PassThroughSerializationManager.cs (1)
70
Manager.PreserveNames && Manager.
Container
?.Components[name] is not null && _resolved.Add(name))
System\ComponentModel\Design\Serialization\DesignerSerializationManager.cs (12)
235
if (instance is null && addToContainer &&
Container
is not null)
237
instance =
Container
.Components[name];
259
if (instance is null && addToContainer && typeof(IComponent).IsAssignableFrom(type) && (argArray is null || argArray.Length == 0 || (argArray.Length == 1 && argArray[0] ==
Container
)))
261
if (GetService(typeof(IDesignerHost)) is IDesignerHost host && host.Container ==
Container
)
267
if (
Container
.Components[name] is not null)
361
if (addToContainer && instance is IComponent component &&
Container
is not null)
367
if (
Container
.Components[name] is not null)
375
Container
.Add(component);
379
Container
.Add(component, name);
540
=> serviceType == typeof(IContainer) ?
Container
: _provider?.GetService(serviceType);
805
if (instance is null && PreserveNames &&
Container
is not null)
807
instance =
Container
.Components[name];
System.Windows.Forms.Design.Tests (6)
System\ComponentModel\Design\Serialization\DesignerSerializationManagerTests.cs (6)
18
Assert.Null(manager.
Container
);
59
Assert.Same(expectedContainer, manager.
Container
);
60
Assert.Same(manager.
Container
, manager.
Container
);
90
Assert.Same(value, manager.
Container
);
95
Assert.Same(value, manager.
Container
);