UIImageView does not show Image from UIImagePickerController

后端 未结 2 2032
被撕碎了的回忆
被撕碎了的回忆 2021-01-28 01:10

I am trying to take a picture with my app and then show it in a UIImageView that is predefined in my .xib. I have a IBOutlet UIImageView *_foto that is linked to the UIImageView

2条回答
  •  天命终不由人
    2021-01-28 01:38

    Artur Ozierański's answer is partially correct.

    If you're using viewDidLayoutSubviews() to configure your layout, this gets called when the picker disappears, so if you're setting the default image in viewDidLayoutSubviews(), you'll reset back to the default image.

    Configure the default image in viewDidLoad.

提交回复
热议问题