在android系统Undersanding动画功能 [英] Undersanding animation function in android

查看:148
本文介绍了在android系统Undersanding动画功能的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我想用下面的code片段,请帮我理解给定函数或建议我,我可以使用在线文档。

I want to use the following code snippet, please help me in understanding the given functions or suggest me online documentation that can I use.

view.animate().setDuration(2000).alpha(0)
        .withEndAction(new Runnable() {
          @Override
          public void run() {
            list.remove(item);
            adapter.notifyDataSetChanged();
            view.setAlpha(1);
          }
      });

什么功能 setDuration(2000)阿尔法(0)。阿尔法(1) withEndAction()

推荐答案


  • setDuration(2000)设置动画的持续时间为2000毫秒或2秒

  • α(0)视图的alpha属性将动画为这个值

  • withEndAction()表示在动画了以下行动将于年底

  • setDuration(2000) sets the duration of the animation to 2000 milliseconds or 2 seconds
  • alpha(0) the view's alpha property will be animated to this value
  • withEndAction() means at the end of the animation the following action will take place
  • 看看这里(的http://developer.android.com/reference/android/view/ViewPropertyAnimator.html)

    这篇关于在android系统Undersanding动画功能的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆