首页 > 如何让一个View旋转并缩小

如何让一个View旋转并缩小

我在实现一个View的旋转

    [UIView animateWithDuration:0.4 delay:0.0 options:UIViewAnimationOptionCurveEaseInOut
                     animations:^(void) {
                         self.lb.transform = CGAffineTransformMakeRotation(3.14f);
                         self.lb.backgroundColor = [[UIColor alloc] initWithRed:220.0/255.0 green:220.0/255.0 blue:220.0/255.0 alpha:1.0];
                     }completion:nil];

可以实现View的旋转,变灰。
我的需求是,旋转变灰,缩小到消失。
请问我该怎么做


    [UIView animateWithDuration:0.4 delay:0.0 options:UIViewAnimationOptionCurveEaseInOut
                     animations:^(void) {
                         CGAffineTransform t = CGAffineTransformMakeRotation(3.14f);
                         CGAffineTransformScale(t, 0, 0);
                         self.lb.transform = t;
                         self.lb.backgroundColor = [[UIColor alloc] initWithRed:220.0/255.0 green:220.0/255.0 blue:220.0/255.0 alpha:1.0];
                     }completion:nil];
【热门文章】
【热门文章】