FrameworkElement.GetUIParentCore 方法


如果没有视觉父级,则返回此元素的备用逻辑父级。Returns an alternative logical parent for this element if there is no visual parent.

protected public:
 override System::Windows::DependencyObject ^ GetUIParentCore();
protected internal override System.Windows.DependencyObject GetUIParentCore ();
override this.GetUIParentCore : unit -> System.Windows.DependencyObject
Protected Friend Overrides Function GetUIParentCore () As DependencyObject


当此方法的 WPF 框架级别实现具有非视觉父级连接时,即返回 null 之外的内容。Returns something other than null whenever a WPF framework-level implementation of this method has a non-visual parent connection.


此方法重写 UIElement.GetUIParentCoreThis method overrides UIElement.GetUIParentCore. 默认 FrameworkElement 实现返回预期的单个可视父级,这与获取 Parent 值的结果相同。The default FrameworkElement implementation returns the expected single visual parent, which is the same result as getting the Parent value. 派生类实现可能返回备用的父关系。Derived class implementations might return alternate parent relationships.