zoukankan      html  css  js  c++  java
  • iOS中的Block动画

    // block动画1

       /*

        [UIView animateWithDuration:1 animations:^(void) {

       

            [UIView setAnimationCurve:UIViewAnimationCurveEaseOut];

            [UIView setAnimationDelegate:self];

            view1.center = CGPointMake(0, 0);

        }];

     

        // block动画2

    /*

        [UIView animateWithDuration:1 animations:^(void){

           

            [UIView setAnimationCurve:UIViewAnimationCurveEaseOut];

            view1.center = CGPointMake(0, 0);

           

        } completion:^(BOOL finished) {

           

            NSLog(@"finished");

        }];

    */

     

      // block动画3

       /*

        [UIView animateWithDuration:1 delay:0 options:UIViewAnimationOptionCurveEaseOut | UIViewAnimationOptionRepeat animations:^(void) {

           

            view1.center = CGPointMake(0, 0);

           

        } completion:^(BOOL finished) {

            NSLog(@"finished");

        }];

         */

       

        // block动画4

       

        [UIViewtransitionFromView:view2toView:view1duration:1options:UIViewAnimationOptionTransitionFlipFromTopcompletion:^(BOOL finished) {

            NSLog(@"finished");

        }];

     

    • animateWithDuration:delay:options:animations:completion:
    • animateWithDuration:animations:completion:
    • animateWithDuration:animations:
    • transitionWithView:duration:options:animations:completion:
    • transitionFromView:toView:duration:options:completion:
  • 相关阅读:
    C#实现二维码生成与解码
    js中正则表达式使用
    Busybox镜像
    linux删除文件后,空间未释放的一种情况,使用lsof查看
    linux中.nfsxxxx引起的文件无法删除
    linux中的查找命令find,locate,which,whereis
    openj9
    Ali流量控制中间件Sentinel
    LDAP认证模式简介
    nginx支持ipv6
  • 原文地址:https://www.cnblogs.com/changjiang/p/3064038.html
Copyright © 2011-2022 走看看