我有一个视图控制器,我认为我将使用UIView动画来解散,将其缩小到0,然后再删除它.我的解雇代码是:
[UIView animateWithDuration:_dismissAnimationDuration delay:0.0 options:UIViewAnimationOptionCurveEaseIn animations:^(void) { _menuContainerView.transform = CGAffineTransformMakeScale(0.0,0.0); } completion:^(BOOL finished){ if ([_delegate respondsToSelector:@selector(popUpMenuDidClose)]) { [_delegate popUpMenuDidClose]; } [self.view removeFromSuperview]; [self removeFromParentViewController]; }];
当从XCode 5构建到运行iOS 7和iOS 8的设备上时,这是非常有效的.但是,一旦我从XCode 6(beta 6和beta 7)构建到iOS 8,这个视图就会切换而不是动画.如果一旦将目标规模改为(0.001,0.001),那么这一点并不奇怪,无论XCode版本如何,它都会动态化.任何想法,为什么我不能用XCode 6动画实际(0.0,0.0)的比例?