Summary
Finds first ancestor of given type.
- Namespace
- Avalonia
.LogicalTree - Containing Type
- LogicalExtensions
Syntax
public static T FindLogicalAncestorOfType<T>(this ILogical logical, bool includeSelf = false)
where T : class
Type Parameters
Name | Description |
---|---|
T | Ancestor type. |
Parameters
Name | Type | Description |
---|---|---|
logical | ILogical | The logical. |
includeSelf | bool | If given logical should be included in search. |
Return Value
Type | Description |
---|---|
T | First ancestor of given type. |