Why is my UIView not growing with CGAffineTransformMakeScale?

后端 未结 2 1595
醉话见心
醉话见心 2021-01-27 09:48

My goal is to make a view grow double in size. The result I get with the code I have is \"nothing happens\". The view displays but doesn\'t grow. Any help would be appreciated.<

2条回答
  •  旧巷少年郎
    2021-01-27 10:09

    When you see the square on screen, the transformation is already happened. Try putting the scaling code in viewDidAppear instead of viewWillAppear.

    Another small remark: you forgot to call

    [super viewWillAppear]. 
    

提交回复
热议问题