The method signature for the did stop delegate selector is
- (void)animationDidStop:(NSString *)animationID finished:(NSNumber *)finished context:(void *)context;
The finished
parameter is an NSNumber
that wraps up a boolean value. In Objective-C and other languages, any non-zero value is considered true (even negative numbers).
You can call [finished boolValue]
on the NSNumber instance to get a true BOOL
, YES
or NO
value.
The finished
boolean value will be NO
if the animation was cancelled or otherwise interrupted before completing it's full animation. If the animation ran through fully, then it will be YES
.
From the docs:
finished
An NSNumber
object containing a Boolean value. The value is YES
if the animation ran to completion before it stopped or NO
if it did not.