小编Luc*_*uke的帖子

Android:如何使用Interpolator制作水平进度条?

我有一个这样的进度条视图:

<ProgressBar
    android:id="@+id/progress_bar"
    android:layout_width="fill_parent"
    android:layout_height="wrap_content"
    android:max="100"/>
Run Code Online (Sandbox Code Playgroud)

它持续3秒,那么如何使用插值器进行平滑更新?

ObjectAnimator animation = ObjectAnimator.ofInt(what_is_in_here?); 
animation.setDuration(3000); //  second
animation.setInterpolator(new DecelerateInterpolator());
animation.start();
Run Code Online (Sandbox Code Playgroud)

我非常感谢你的帮助.非常感谢你提前.

android linear-interpolation

10
推荐指数
1
解决办法
6960
查看次数

标签 统计

android ×1

linear-interpolation ×1