Class DependencyObjectExtensions
Provides extension methods for the DependencyObject type.
Namespace: Celestial.UIToolkit.Extensions
Assembly: Celestial.UIToolkit.Core.dll
Syntax
public static class DependencyObjectExtensions
Methods
| Improve this Doc View SourceHasVisualAncestor(DependencyObject, DependencyObject)
Returns a value indicating whether the provided ancestor
is one of the current dependency object's ancestor in the visual tree.
Declaration
public static bool HasVisualAncestor(this DependencyObject depObj, DependencyObject ancestor)
Parameters
Type | Name | Description |
---|---|---|
DependencyObject | depObj | The dependency object. |
DependencyObject | ancestor | A potential ancestor. |
Returns
Type | Description |
---|---|
Boolean | true if |
RemoveLogicalChild(DependencyObject, UIElement)
Tries to remove the specified child
from the elements logical
tree.
Declaration
public static void RemoveLogicalChild(this DependencyObject parent, UIElement child)
Parameters
Type | Name | Description |
---|---|---|
DependencyObject | parent | The parent. |
UIElement | child | The child to be removed. |