AvaloniaObjectSetAndRaiseT Method

Sets the backing field for a direct avalonia property, raising the PropertyChanged event if the value has changed.

Definition

Namespace: Avalonia
Assembly: Avalonia.Base (in Avalonia.Base.dll) Version: 11.3.999
protected bool SetAndRaise<T>(
	DirectPropertyBase<T> property,
	ref T field,
	T value
)

Parameters

property  DirectPropertyBaseT
The property.
field  T
The backing field.
value  T
The value.

Type Parameters

T
The type of the property.

Return Value

Boolean
True if the value changed, otherwise false.

See Also