summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorTony Wickham <twickham@google.com>2018-05-24 17:13:36 -0700
committerTony Wickham <twickham@google.com>2018-05-24 22:48:46 -0700
commit4ff7d8e7b37f92420159e0eda41f38b34aaada24 (patch)
tree544a4835e2b162d60052b074442cac635effb470
parent1ab656460b7baf9ac9233eab3e9582abb8d6941c (diff)
downloadandroid_packages_apps_Trebuchet-4ff7d8e7b37f92420159e0eda41f38b34aaada24.tar.gz
android_packages_apps_Trebuchet-4ff7d8e7b37f92420159e0eda41f38b34aaada24.tar.bz2
android_packages_apps_Trebuchet-4ff7d8e7b37f92420159e0eda41f38b34aaada24.zip
Use correct interpolator for recents scale when quick scrubbing
Use same interpolator for scale and translationY so that they feel more coordinated. (They were already the same in all cases except when scrubbing when already in overview, which never had a scale component before.) Bug: 80139193 Change-Id: Id143b5cc9279d55aaa1b0444db5fe4b41ce92170
-rw-r--r--quickstep/src/com/android/launcher3/uioverrides/RecentsViewStateController.java13
1 files changed, 7 insertions, 6 deletions
diff --git a/quickstep/src/com/android/launcher3/uioverrides/RecentsViewStateController.java b/quickstep/src/com/android/launcher3/uioverrides/RecentsViewStateController.java
index e3aabd6c8..ea27eb25b 100644
--- a/quickstep/src/com/android/launcher3/uioverrides/RecentsViewStateController.java
+++ b/quickstep/src/com/android/launcher3/uioverrides/RecentsViewStateController.java
@@ -76,15 +76,16 @@ public class RecentsViewStateController implements StateHandler {
}
PropertySetter setter = config.getPropertySetter(builder);
float[] scaleTranslationYFactor = toState.getOverviewScaleAndTranslationYFactor(mLauncher);
- Interpolator scaleInterpolator = builder.getInterpolator(ANIM_OVERVIEW_SCALE, LINEAR);
- setter.setFloat(mRecentsView, SCALE_PROPERTY, scaleTranslationYFactor[0], scaleInterpolator);
- Interpolator transYInterpolator = scaleInterpolator;
+ Interpolator scaleAndTransYInterpolator = builder.getInterpolator(
+ ANIM_OVERVIEW_SCALE, LINEAR);
if (mLauncher.getStateManager().getState() == OVERVIEW && toState == FAST_OVERVIEW) {
- transYInterpolator = Interpolators.clampToProgress(QUICK_SCRUB_START_INTERPOLATOR, 0,
- QUICK_SCRUB_TRANSLATION_Y_FACTOR);
+ scaleAndTransYInterpolator = Interpolators.clampToProgress(
+ QUICK_SCRUB_START_INTERPOLATOR, 0, QUICK_SCRUB_TRANSLATION_Y_FACTOR);
}
+ setter.setFloat(mRecentsView, SCALE_PROPERTY, scaleTranslationYFactor[0],
+ scaleAndTransYInterpolator);
setter.setFloat(mRecentsView, TRANSLATION_Y_FACTOR, scaleTranslationYFactor[1],
- transYInterpolator);
+ scaleAndTransYInterpolator);
setter.setFloat(mRecentsViewContainer, CONTENT_ALPHA, toState.overviewUi ? 1 : 0,
builder.getInterpolator(ANIM_OVERVIEW_FADE, AGGRESSIVE_EASE_IN_OUT));