protected override void UpdateDataValidation(AvaloniaProperty property, BindingNotification status) { if (property == TextProperty) { DataValidationErrors.SetError(this, status.Error); } }
protected override void OnPropertyChanged <T>(AvaloniaPropertyChangedEventArgs <T> change) { base.OnPropertyChanged(change); if (change.Property == SelectedDateProperty) { DataValidationErrors.SetError(this, change.NewValue.Error); } }
/// <inheritdoc/> protected override void UpdateDataValidation(AvaloniaProperty property, BindingValueType state, Exception?error) { if (property == SelectedDateProperty) { DataValidationErrors.SetError(this, error); } base.UpdateDataValidation(property, state, error); }
protected override void OnPropertyChanged <T>( AvaloniaProperty <T> property, Optional <T> oldValue, BindingValue <T> newValue, BindingPriority priority) { base.OnPropertyChanged(property, oldValue, newValue, priority); if (property == SelectedDateProperty) { DataValidationErrors.SetError(this, newValue.Error); } }