我试图在设置WPF中的Dependency / Attached属性时调用PropertyChangedCallback与调用CoerceValueCallback之间的区别。
例如
public static readonly DependencyProperty ValueProperty = DependencyProperty.RegisterAttached(
"Value",
typeof(TProperty),
typeof(BaseAttachedProperty<TParent, TProperty>),
new PropertyMetadata(default(TProperty),
new PropertyChangedCallback(PropertyChanged),
new CoerceValueCallback(CoerceCallback)));
如果我有一个名为ValueProperty的依赖项属性,它有一个PropertyChangedCallback的委托PropertyChanged和CoerceValueCallback的委托CoerceCallback,它们何时被调用?