Adding custom slide up activity transition for L MR1
issue 21402755
Change-Id: Id2542c0a3c38bd71aa407a3b0fe00fdee24e2f69
diff --git a/src/com/android/launcher3/Launcher.java b/src/com/android/launcher3/Launcher.java
index 0a20fa4..4e83a67 100644
--- a/src/com/android/launcher3/Launcher.java
+++ b/src/com/android/launcher3/Launcher.java
@@ -2899,8 +2899,15 @@
}
}
if (opts == null && !Utilities.isLmpOrAbove()) {
+ // Below L, we use a scale up animation
opts = ActivityOptions.makeScaleUpAnimation(v, 0, 0,
v.getMeasuredWidth(), v.getMeasuredHeight());
+ } else if (opts == null && Utilities.isLmpMR1()) {
+ // On L devices, we use the device default slide-up transition.
+ // On L MR1 devices, we a custom version of the slide-up transition which
+ // doesn't have the delay present in the device default.
+ opts = ActivityOptions.makeCustomAnimation(this,
+ R.anim.task_open_enter, R.anim.no_anim);
}
optsBundle = opts != null ? opts.toBundle() : null;
}