Visual.IsDescendantOf(DependencyObject) Visual.IsDescendantOf(DependencyObject) Visual.IsDescendantOf(DependencyObject) Visual.IsDescendantOf(DependencyObject) Method

定义

确定可视对象是否为上级可视对象的后代。Determines whether the visual object is a descendant of the ancestor visual object.

public:
 bool IsDescendantOf(System::Windows::DependencyObject ^ ancestor);
public bool IsDescendantOf (System.Windows.DependencyObject ancestor);
member this.IsDescendantOf : System.Windows.DependencyObject -> bool
Public Function IsDescendantOf (ancestor As DependencyObject) As Boolean

参数

返回

如果可视对象是 ancestor 的后代,则为 true;否则为 falsetrue if the visual object is a descendant of ancestor; otherwise, false.

适用于