Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 1f5e5d57 authored by Matthew Ng's avatar Matthew Ng Committed by android-build-merger
Browse files

Merge "Fix back button not disappearing" into qt-dev

am: e1bdc4b0

Change-Id: I7b7eeea1b6c3939c7ddc7d3bd69d8c5bc8e0ae0c
parents 9b8f834e e1bdc4b0
Loading
Loading
Loading
Loading
+2 −2
Original line number Diff line number Diff line
@@ -61,6 +61,7 @@ public class ButtonDispatcher {
    private final AnimatorListenerAdapter mFadeListener = new AnimatorListenerAdapter() {
        @Override
        public void onAnimationEnd(Animator animation) {
            mFadeAnimator = null;
            setVisibility(getAlpha() == 1 ? View.VISIBLE : View.INVISIBLE);
        }
    };
@@ -143,7 +144,6 @@ public class ButtonDispatcher {
        if (mVisibility == visibility) return;
        if (mFadeAnimator != null) {
            mFadeAnimator.cancel();
            mFadeAnimator = null;
        }

        mVisibility = visibility;
@@ -176,13 +176,13 @@ public class ButtonDispatcher {
            if (mFadeAnimator != null) {
                mFadeAnimator.cancel();
            }
            setVisibility(View.VISIBLE);
            mFadeAnimator = ValueAnimator.ofFloat(getAlpha(), alpha);
            mFadeAnimator.setDuration(duration);
            mFadeAnimator.setInterpolator(getAlpha() < alpha ? ALPHA_IN : ALPHA_OUT);
            mFadeAnimator.addListener(mFadeListener);
            mFadeAnimator.addUpdateListener(mAlphaListener);
            mFadeAnimator.start();
            setVisibility(View.VISIBLE);
        } else {
            mAlpha = alpha;
            final int N = mViews.size();