CABasicAnimation resets to initial value after animation completes

Here’s the answer, it’s a combination of my answer and Krishnan’s.

cabasicanimation.fillMode = kCAFillModeForwards;
cabasicanimation.removedOnCompletion = NO;

The default value is kCAFillModeRemoved. (Which is the reset behavior you’re seeing.)

Leave a Comment