hitTest:

Returns the farthest descendant of the receiver in the layer hierarchy (including itself) that contains a specified point.

Declaration

- (CALayer *)hitTest:(CGPoint)thePoint

Parameters

thePoint

A point in the coordinate system of the receiver's superlayer.

Return Value

The layer that contains thePoint, or nil if the point lies outside the receiver’s bounds rectangle.

Overview

Transform layers do not support hit-testing. As a result, you should not send hitTest: messages to transform layers.

See Also