1
1
mirror of https://github.com/exyte/Macaw.git synced 2024-11-11 01:42:35 +03:00

Fix #285: Add method to MacawView to find node at specified location

This commit is contained in:
Alisa Mylnikova 2018-04-04 14:09:53 +07:00
parent 54a417be7d
commit 10996a4b82

View File

@ -168,6 +168,11 @@ open class MacawView: MView, MGestureRecognizerDelegate {
}
MGraphicsEndImageContext()
}
public final func findNodeAt(location: CGPoint) -> Node? {
guard let ctx = context.cgContext else { return .none }
return renderer?.findNodeAt(location: location, ctx: ctx)
}
// MARK: - Touches