Share via


Element.OnChildAdded(Element) 方法

定义

引发 ChildAdded 事件。 实现此方法可为此事件添加类处理。

protected:
 virtual void OnChildAdded(Microsoft::Maui::Controls::Element ^ child);
protected virtual void OnChildAdded (Microsoft.Maui.Controls.Element child);
abstract member OnChildAdded : Microsoft.Maui.Controls.Element -> unit
override this.OnChildAdded : Microsoft.Maui.Controls.Element -> unit
Protected Overridable Sub OnChildAdded (child As Element)

参数

child
Element

作为子元素添加的元素。

注解

此方法没有默认实现。 如果中间类实现了此方法,仍应调用基实现。

适用于