summaryrefslogtreecommitdiffstats
path: root/tests
diff options
context:
space:
mode:
authorJohn Reck <jreck@google.com>2014-05-12 22:11:00 +0000
committerAndroid (Google) Code Review <android-gerrit@google.com>2014-05-12 22:11:00 +0000
commitcae6873161fd0794a794ef487c40074ee7e815aa (patch)
tree4e81d048313c8d9588daf5ff312fbd9b29306a9b /tests
parent0e8a427ab802d07aea4a7d6584cacf4a64b93de9 (diff)
parent315c329544d7c593d1072b071cbb92d9afe74021 (diff)
downloadframeworks_base-cae6873161fd0794a794ef487c40074ee7e815aa.zip
frameworks_base-cae6873161fd0794a794ef487c40074ee7e815aa.tar.gz
frameworks_base-cae6873161fd0794a794ef487c40074ee7e815aa.tar.bz2
Merge "Add TimeInterpolator support to RNA"
Diffstat (limited to 'tests')
-rw-r--r--tests/HwAccelerationTest/src/com/android/test/hwui/CirclePropActivity.java8
1 files changed, 7 insertions, 1 deletions
diff --git a/tests/HwAccelerationTest/src/com/android/test/hwui/CirclePropActivity.java b/tests/HwAccelerationTest/src/com/android/test/hwui/CirclePropActivity.java
index 5c273de..1d0a806 100644
--- a/tests/HwAccelerationTest/src/com/android/test/hwui/CirclePropActivity.java
+++ b/tests/HwAccelerationTest/src/com/android/test/hwui/CirclePropActivity.java
@@ -16,6 +16,7 @@
package com.android.test.hwui;
+import android.animation.TimeInterpolator;
import android.app.Activity;
import android.content.Context;
import android.graphics.Canvas;
@@ -27,6 +28,8 @@ import android.os.Trace;
import android.view.HardwareCanvas;
import android.view.RenderNodeAnimator;
import android.view.View;
+import android.view.animation.AccelerateDecelerateInterpolator;
+import android.view.animation.OvershootInterpolator;
import android.webkit.WebChromeClient;
import android.webkit.WebView;
import android.webkit.WebViewClient;
@@ -122,8 +125,11 @@ public class CirclePropActivity extends Activity {
mPaint, RenderNodeAnimator.PAINT_STROKE_WIDTH,
RenderNodeAnimator.DELTA_TYPE_ABSOLUTE, mToggle ? 5.0f : 60.0f));
+ TimeInterpolator interp = new OvershootInterpolator(3.0f);
for (int i = 0; i < mRunningAnimations.size(); i++) {
- mRunningAnimations.get(i).start(this);
+ RenderNodeAnimator anim = mRunningAnimations.get(i);
+ anim.setInterpolator(interp);
+ anim.start(this);
}
if (mToggle) {