Instance Method

touchesShouldCancelInContentView:

Returns whether to cancel touches related to the content subview and start dragging.

Declaration

- (BOOL)touchesShouldCancelInContentView:(UIView *)view;

Parameters

view

The view object in the content that is being touched.

Return Value

YES to cancel further touch messages to view, NO to have view continue to receive those messages. The default returned value is YES if view is not a UIControl object; otherwise, it returns NO.

Discussion

The scroll view calls this method just after it starts sending tracking messages to the content view. If it receives NO from this method, it stops dragging and forwards the touch events to the content subview. The scroll view does not call this method if the value of the canCancelContentTouches property is NO.

See Also

Managing Touches

touchesShouldBegin:withEvent:inContentView:

Overridden by subclasses to customize the default behavior when a finger touches down in displayed content.

canCancelContentTouches

A Boolean value that controls whether touches in the content view always lead to tracking.

delaysContentTouches

A Boolean value that determines whether the scroll view delays the handling of touch-down gestures.

directionalPressGestureRecognizer

The underlying gesture recognizer for directional button presses.