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

Commit bc7744b9 authored by Joshua Tsuji's avatar Joshua Tsuji
Browse files

Don't allow the overflow bubble to be dragged out.

Test: Try and fail to drag out the overflow bubble. Also quick-fling it towards where the dismiss target would be and observe that sysui doesn't crash.
Fixes: 149870727
Change-Id: I23fdfa3a9b0e1b3722704bfc28d5ef42c3bf66c4
parent 7be4c616
Loading
Loading
Loading
Loading
+7 −2
Original line number Diff line number Diff line
@@ -1386,6 +1386,11 @@ public class BubbleStackView extends FrameLayout {
        if (DEBUG_BUBBLE_STACK_VIEW) {
            Log.d(TAG, "onBubbleDragStart: bubble=" + bubble);
        }

        if (bubble.equals(mBubbleOverflow.getIconView())) {
            return;
        }

        mExpandedAnimationController.prepareForBubbleDrag(bubble, mMagneticTarget);

        // We're dragging an individual bubble, so set the magnetized object to the magnetized
@@ -1398,7 +1403,7 @@ public class BubbleStackView extends FrameLayout {

    /** Called with the coordinates to which an individual bubble has been dragged. */
    public void onBubbleDragged(View bubble, float x, float y) {
        if (!mIsExpanded || mIsExpansionAnimating) {
        if (!mIsExpanded || mIsExpansionAnimating || bubble.equals(mBubbleOverflow.getIconView())) {
            return;
        }

@@ -1413,7 +1418,7 @@ public class BubbleStackView extends FrameLayout {
            Log.d(TAG, "onBubbleDragFinish: bubble=" + bubble);
        }

        if (!mIsExpanded || mIsExpansionAnimating) {
        if (!mIsExpanded || mIsExpansionAnimating || bubble.equals(mBubbleOverflow.getIconView())) {
            return;
        }