我是Objective-c和编码的新手,我正在努力找出我想为程序编写的代码。当我按下按钮然后返回到原始大小时,我希望我的图像缩放到0。到目前为止,我能够将其缩放到0,但我不知道如何将其恢复到原始大小。
-(void)rotate_imageview
{
[UIView animateWithDUration: 0.5 delay:0.0 options:UIViewAnimateOptionCurveLinear
animations:^{
CGAffineTransform Scale = CGAffineTransformMakeScale(0, 0);
CGAffineTransform translate = CGAFffineTransformMakeTranslation(10.0, 10.0);
self.imageview.transform = CGAffineTransformConcat(scale, translate);
}
completion:^(BOOL finished) {
}];