I have a
I found the solution to this problem. Other answers are partially correct and are helpful.
The following points are important to understanding the solution:
In order to solve, we are going to have to tap into Core Animation ourselves, and can't rely on the UIView animation block to do the work for us.
Simply create a
CATransaction with the same duration that you are using with
[UIView animateWithDuration:...]. This will create a separate animation, but if your durations and easing function is the same, it should animate exactly with the other animations in your animation block.
NSTimeInterval duration = 0.5;// match this to the value of the UIView animateWithDuration: call [CATransaction begin]; [CATransaction setValue:[NSNumber numberWithFloat:duration] forKey:kCATransactionAnimationDuration]; self.myView.layer.mask.position = CGPointMake(newX, 0); self.myView.layer.mask.bounds = CGRectMake(0, 0, newWidth, newHeight); [CATransaction commit];