Instance Method

continueTrackingWithTouch:withEvent:

Called when a touch event associated with the control is updated.

Declaration

- (BOOL)continueTrackingWithTouch:(UITouch *)touch withEvent:(UIEvent *)event;

Parameters

touch

The touch object containing updated information.

event

The event object containing the touch event.

Return Value

YES if the control should continue tracking touch events or NO if it should stop. This value is used to update the tracking property of the control.

Discussion

This method is called repeatedly while a touch event is being tracked inside the control’s bounds. The default implementation of this method always returns YES. Subclasses can override this method and use it to update their state based on changes to the touch event. If you want to continue tracking the touch event, return YES. If you want to stop tracking the touch event, return NO.

See Also

Tracking Touches and Redrawing Controls

- beginTrackingWithTouch:withEvent:

Called when a touch event enters the control’s bounds.

- endTrackingWithTouch:withEvent:

Called when a touch event associated with the control ends.

- cancelTrackingWithEvent:

Tells the control to cancel tracking related to the given event.

tracking

A Boolean value indicating whether the control is currently tracking touch events.

touchInside

A Boolean value indicating whether a tracked touch event is currently inside the control’s bounds.