Circular button becomes rounded rectangle after size increase

后端 未结 1 779
小蘑菇
小蘑菇 2021-01-22 06:00

I created a circular button in my iOS app and after changing the auto layout width and height constraints (so that the button is bigger) it is now a rounded rectangle instead of

相关标签:
1条回答
  • 2021-01-22 06:35

    Auto Layout happens after viewDidLoad, so you need to move your adjustment to viewDidLayoutSubviews so that the frame size will be set to the correct size.

    0 讨论(0)
提交回复
热议问题