我有一个UIImageView用作背景图像:
lazy var backgroundImageView: UIImageView = {
return UIImageView(frame: CGRect(x: self.view.frame.origin.x, y: self.view.frame.origin.y, width: self.view.frame.width, height: self.view.frame.height))
}()
我在viewDidLoad
上设置了图片:
backgroundImageView.image = (self.router?.dataStore?.image)!
VC自动旋转时,backgroundImageView
也旋转。如何锁定backgroundImageView
?