PropertyMetadata.OnApply(DependencyProperty, Type) Method
Definition
Important
Some information relates to prerelease product that may be substantially modified before it’s released. Microsoft makes no warranties, express or implied, with respect to the information provided here.
Called when this metadata has been applied to a property, which indicates that the metadata is being sealed.
protected:
virtual void OnApply(System::Windows::DependencyProperty ^ dp, Type ^ targetType);
protected virtual void OnApply (System.Windows.DependencyProperty dp, Type targetType);
abstract member OnApply : System.Windows.DependencyProperty * Type -> unit
override this.OnApply : System.Windows.DependencyProperty * Type -> unit
Protected Overridable Sub OnApply (dp As DependencyProperty, targetType As Type)
Parameters
The dependency property to which the metadata has been applied.
- targetType
- Type
The type associated with this metadata if this is type-specific metadata. If this is default metadata, this value is a null reference.
Remarks
Subclasses should assure that any mutability of the data structure of a PropertyMetadata subclass should be marked as immutable once OnApply is called. This will be called once the metadata is applied to a property system operation (register, add owner, override metadata).
Applies to
意見反應
https://aka.ms/ContentUserFeedback。
即將登場:在 2024 年,我們將逐步淘汰 GitHub 問題作為內容的意見反應機制,並將它取代為新的意見反應系統。 如需詳細資訊,請參閱:提交並檢視相關的意見反應