Merge "Stash taskbar when IME is present, including during gestures" into sc-v2-dev am: b4aefc1277 am: cc6b8488bf
Original change: https://googleplex-android-review.googlesource.com/c/platform/packages/apps/Launcher3/+/16325264 Change-Id: I7c71ae9aa8c949907286c31a2e6c75871e599ec7
This commit is contained in:
commit
a930bca528
12 files changed
+200
-84
No files matched your search
@@ -26,9 +26,27 @@ public abstract class RevealOutlineAnimation extends ViewOutlineProvider {
|
||||
/** Sets the progress, from 0 to 1, of the reveal animation. */
|
||||
abstract void setProgress(float progress);
|
||||
|
||||
/**
|
||||
* @see #createRevealAnimator(View, boolean, float) where startProgress is set to 0.
|
||||
*/
|
||||
public ValueAnimator createRevealAnimator(final View revealView, boolean isReversed) {
|
||||
ValueAnimator va =
|
||||
isReversed ? ValueAnimator.ofFloat(1f, 0f) : ValueAnimator.ofFloat(0f, 1f);
|
||||
return createRevealAnimator(revealView, isReversed, 0f /* startProgress */);
|
||||
}
|
||||
|
||||
/**
|
||||
* Animates the given View's ViewOutline according to {@link #setProgress(float)}.
|
||||
* @param revealView The View whose outline we are animating.
|
||||
* @param isReversed Whether we are hiding rather than revealing the View.
|
||||
* @param startProgress The progress at which to start the newly created animation. Useful if
|
||||
* the previous reveal animation was cancelled and we want to create a new animation where it
|
||||
* left off. Note that if isReversed=true, we start at 1 - startProgress (and go to 0).
|
||||
* @return The Animator, which the caller must start.
|
||||
*/
|
||||
public ValueAnimator createRevealAnimator(final View revealView, boolean isReversed,
|
||||
float startProgress) {
|
||||
ValueAnimator va = isReversed
|
||||
? ValueAnimator.ofFloat(1f - startProgress, 0f)
|
||||
: ValueAnimator.ofFloat(startProgress, 1f);
|
||||
final float elevation = revealView.getElevation();
|
||||
|
||||
va.addListener(new AnimatorListenerAdapter() {
|
||||
|
||||
Reference in new issue
Block a user