Different maskedCorners for different views don't animate properly
tkuziola opened this issue · 2 comments
tkuziola commented
What did you do?
I have two views in two different viewControllers:
OneViewController
containerView.layer.cornerRadius = 40
containerView.layer.maskedCorners = [.layerMaxXMinYCorner]
TwoViewController
containerView.layer.cornerRadius = 40
containerView.layer.maskedCorners = [.layerMaxXMinYCorner, .layerMinXMaxYCorner, .layerMaxXMaxYCorner]
What did you expect to happen?
I expected that It will smoothly animate corners that aren't rounded to rounded in the second view controller
What happened instead?
One corner that is not rounded (left, top corner) is animated to rounded and after animation it is switched to sharped. Similar thing happened here #40, but this issue was for all corners, not for some of them.
I tried mixing with maskToBounds and clipToBounds, but nothing helped.
General Information
-
Hero Version: 1.5
-
iOS Version(s): 14.3
-
Swift Version: 5
-
Devices/Simulators: iPhone 12 Pro
tkuziola commented
Yep! 1.6 solved the issue!