I’m doing a simple animation of UIView height so that it reveals.
By default it seems to be revealing from top to bottom, and I want it to reveal bottom to top.
I have the UIView anchored to the bottom of the screen.
I’m sure it something simple i’m missing….. any tips?
Thanks
Like a dog with a bone I figured this out….
Instead of animating the frame height, I applied a transform to the view and set the anchor point of the layer.
If I put 0 as the y scale, the view behaves weird…. at the end of the animation i just set it to hidden.
On the way back up I just use the Identity Transform (reset it)
Note that changing my anchor point shifted the position of my view. See this post for the setAnchorPoint method which normalises the view after setting the anchorPoint
Changing my CALayer's anchorPoint moves the view