2 writes to BindableComponent
System.Windows.Forms (2)
System\Windows\Forms\DataBinding\Binding.cs (2)
206
BindableComponent
= value;
215
BindableComponent
= oldTarget;
56 references to BindableComponent
System.Windows.Forms (36)
System\Windows\Forms\DataBinding\Binding.BindToObject.cs (2)
199
if (_owner.
BindableComponent
is not null && _owner.ControlAtDesignTime())
214
&& _owner.
BindableComponent
is not null
System\Windows\Forms\DataBinding\Binding.cs (27)
176
public Control? Control =>
BindableComponent
as Control;
191
internal bool ComponentCreated => IsComponentCreated(
BindableComponent
);
195
Debug.Assert(sender ==
BindableComponent
, "which other control can send us the Load event?");
202
if (
BindableComponent
!= value)
204
IBindableComponent? oldTarget =
BindableComponent
;
222
BindingContext.UpdateBinding((
BindableComponent
is not null && IsComponentCreated(
BindableComponent
) ?
BindableComponent
.BindingContext : null), this);
429
if (
BindableComponent
is null)
441
_propInfo.AddValueChanged(
BindableComponent
, handler);
447
_validateInfo.AddEventHandler(
BindableComponent
, handler);
456
_propInfo.RemoveValueChanged(
BindableComponent
, handler);
462
_validateInfo.RemoveEventHandler(
BindableComponent
, handler);
477
if (
BindableComponent
is not null && !string.IsNullOrEmpty(PropertyName))
479
BindableComponent
.DataBindings.CheckDuplicates(this);
481
Type controlClass =
BindableComponent
.GetType();
495
InheritanceAttribute? attr = (InheritanceAttribute?)TypeDescriptor.GetAttributes(
BindableComponent
)[typeof(InheritanceAttribute)];
502
propInfos = TypeDescriptor.GetProperties(
BindableComponent
);
547
EventDescriptorCollection eventInfos = TypeDescriptor.GetEvents(
BindableComponent
);
571
if (
BindableComponent
is not IComponent comp)
584
if (_propIsNullInfo is not null && (bool?)_propIsNullInfo.GetValue(
BindableComponent
) == true)
589
return _propInfo?.GetValue(
BindableComponent
) ?? DataSourceNullValue;
1052
_propIsNullInfo.SetValue(
BindableComponent
, true);
1058
_propInfo.SetValue(
BindableComponent
, DataSourceNullValue);
1062
_propInfo.SetValue(
BindableComponent
, null);
1068
_propInfo!.SetValue(
BindableComponent
, value);
1134
BindableComponent
is not null
System\Windows\Forms\DataBinding\BindingContext.cs (4)
295
if (propBinding.
BindableComponent
is not null && newBindingContext.Contains(propBinding.
BindableComponent
, string.Empty))
299
BindingManagerBase bindingManagerBase = newBindingContext.EnsureListManager(propBinding.
BindableComponent
, string.Empty);
303
if (binding.DataSource == propBinding.
BindableComponent
)
System\Windows\Forms\DataBinding\ControlBindingsCollection.cs (3)
173
if (dataBinding.
BindableComponent
== _control)
178
if (dataBinding.
BindableComponent
is not null)
244
if (dataBinding.
BindableComponent
!= _control)
System.Windows.Forms.Tests (20)
System\Windows\Forms\BindingContextTests.cs (1)
992
Assert.NotNull(binding.
BindableComponent
);
System\Windows\Forms\BindingTests.cs (6)
25
Assert.Null(binding.
BindableComponent
);
54
Assert.Null(binding.
BindableComponent
);
83
Assert.Null(binding.
BindableComponent
);
112
Assert.Null(binding.
BindableComponent
);
141
Assert.Null(binding.
BindableComponent
);
170
Assert.Null(binding.
BindableComponent
);
System\Windows\Forms\ControlBindingsCollectionTests.cs (13)
63
Assert.Same(control, binding.
BindableComponent
);
128
Assert.Same(control, binding.
BindableComponent
);
145
Assert.Same(control, binding.
BindableComponent
);
162
Assert.Same(control, binding.
BindableComponent
);
179
Assert.Same(control, binding.
BindableComponent
);
196
Assert.Same(control, binding.
BindableComponent
);
213
Assert.Same(control, binding.
BindableComponent
);
308
Assert.Same(control, binding.
BindableComponent
);
312
Assert.Null(binding.
BindableComponent
);
328
Assert.Same(control, binding.
BindableComponent
);
332
Assert.Null(binding.
BindableComponent
);
386
Assert.Same(control, binding.
BindableComponent
);
390
Assert.Null(binding.
BindableComponent
);