美文网首页
iOS炫酷的转场动画

iOS炫酷的转场动画

作者: 在路上浅谈管理 | 来源:发表于2019-07-23 11:13 被阅读0次

先来看看效果:


1801563-f6793ea51c9453e6.gif
1801563-7c7f0def50ca8269.gif
1801563-f5d8172f7c7828d7.gif
1801563-348ead15ab2669d3.gif
1801563-6470fad4670f7667.gif
1801563-050c35c20e37dc17.gif
1801563-593d5fdefc759f97.gif
1801563-b8d20580229e1769.gif
1801563-061c95cfd7d776d1.gif
1801563-81247a4213d193ca.gif
1801563-5730903fa2d97c10.gif
1801563-e077c0e8ff06b09d.gif
1801563-7f659c63c9731968.gif

使用方法:

1、导入头文件UIViewController+HHTransition
2、调用如下方法,基本只需要一句话,无侵入,API简单易用

        case 0:
            [self.navigationController hh_presentCircleVC:[CircleViewController new] point:_touchPoint completion:nil];
            break;
        case 1:
            [self.navigationController hh_presentBackScaleVC:[BackScaleViewController new] height:400 completion:nil];
            break;
        case 2:
            [self.navigationController hh_presentErectVC:[CircleViewController new] completion:nil];
            break;
        case 3:{//需要重写 hh_transitionAnimationView
           InterScaleViewController *interScale = [InterScaleViewController new];
            interScale.imageName = [UIImage imageNamed:@"1.jpg"];
            [self.navigationController hh_pushScaleViewController:interScale];
        }
            break;
        case 4:{//需要重写 hh_transitionAnimationView
            InterScaleViewController *interScale = [InterScaleViewController new];
            interScale.imageName = [UIImage imageNamed:@"2.jpg"];
            [self.navigationController hh_pushScaleViewController:interScale];
        }
            break;
        case 5:
            [self.navigationController hh_pushTiltViewController:[CircleViewController new]];
            break;
        case 6:
            [self.navigationController hh_pushErectViewController:[CircleViewController new]];
            break;
        case 7:
            [self.navigationController hh_pushBackViewController:[CircleViewController new]];
            break;
        default:
            break;

下载地址:Github

支持cocoapod:

target 'MyApp' do
  pod 'HHTransition', '~> 1.0'
end

原文章地址:https://www.jianshu.com/p/fbfbcb75dc4b

相关文章

网友评论

      本文标题:iOS炫酷的转场动画

      本文链接:https://www.haomeiwen.com/subject/vrcolctx.html