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

Commit e1701b05 authored by Ats Jenk's avatar Ats Jenk Committed by Android (Google) Code Review
Browse files

Merge "Skip bubble bar arrow animation if arrow detached" into main

parents 05ca003b e0b2ef48
Loading
Loading
Loading
Loading
+5 −2
Original line number Diff line number Diff line
@@ -425,9 +425,12 @@ public class BubbleBarView extends FrameLayout {
        }
        // Find the center of the bubble when it's expanded, set the arrow position to it.
        final float tx = arrowPositionForSelectedWhenExpanded();

        if (shouldAnimate) {
        final float currentArrowPosition = mBubbleBarBackground.getArrowPositionX();
        if (shouldAnimate && currentArrowPosition > expandedWidth()) {
            Log.d(TAG, "arrow out of bounds of expanded view, skip animation");
            shouldAnimate = false;
        }
        if (shouldAnimate) {
            ValueAnimator animator = ValueAnimator.ofFloat(currentArrowPosition, tx);
            animator.setDuration(ARROW_POSITION_ANIMATION_DURATION_MS);
            animator.addUpdateListener(animation -> {