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

Commit bcfd8a36 authored by TreeHugger Robot's avatar TreeHugger Robot Committed by Automerger Merge Worker
Browse files

Merge "Delete BubbleTouchHandler in favor of more traditional touch handling."...

Merge "Delete BubbleTouchHandler in favor of more traditional touch handling." into rvc-dev am: 8fc6e456

Change-Id: Ib7b240c66fb49ec526ea40f5c658704e3413a3fc
parents 729207db 8fc6e456
Loading
Loading
Loading
Loading
+0 −20
Original line number Diff line number Diff line
@@ -718,13 +718,6 @@ public class BubbleController implements ConfigurationController.ConfigurationLi
        return mBubbleData.isExpanded();
    }

    /**
     * Tell the stack of bubbles to expand.
     */
    public void expandStack() {
        mBubbleData.setExpanded(true);
    }

    /**
     * Tell the stack of bubbles to collapse.
     */
@@ -753,12 +746,6 @@ public class BubbleController implements ConfigurationController.ConfigurationLi
        return (isSummary && isSuppressedSummary) || isBubbleAndSuppressed;
    }

    @VisibleForTesting
    void selectBubble(String key) {
        Bubble bubble = mBubbleData.getBubbleWithKey(key);
        mBubbleData.setSelectedBubble(bubble);
    }

    void promoteBubbleFromOverflow(Bubble bubble) {
        bubble.setInflateSynchronously(mInflateSynchronously);
        mBubbleData.promoteBubbleFromOverflow(bubble, mStackView, mBubbleIconFactory);
@@ -777,13 +764,6 @@ public class BubbleController implements ConfigurationController.ConfigurationLi
        }
    }

    /**
     * Tell the stack of bubbles to be dismissed, this will remove all of the bubbles in the stack.
     */
    void dismissStack(@DismissReason int reason) {
        mBubbleData.dismissAll(reason);
    }

    /**
     * Directs a back gesture at the bubble stack. When opened, the current expanded bubble
     * is forwarded a back key down/up pair.
+13 −0
Original line number Diff line number Diff line
@@ -28,6 +28,7 @@ import android.content.Context;
import android.service.notification.NotificationListenerService;
import android.util.Log;
import android.util.Pair;
import android.view.View;

import androidx.annotation.Nullable;

@@ -751,6 +752,7 @@ public class BubbleData {
    }

    @VisibleForTesting(visibility = PRIVATE)
    @Nullable
    Bubble getBubbleWithKey(String key) {
        for (int i = 0; i < mBubbles.size(); i++) {
            Bubble bubble = mBubbles.get(i);
@@ -761,6 +763,17 @@ public class BubbleData {
        return null;
    }

    @Nullable
    Bubble getBubbleWithView(View view) {
        for (int i = 0; i < mBubbles.size(); i++) {
            Bubble bubble = mBubbles.get(i);
            if (bubble.getIconView() != null && bubble.getIconView().equals(view)) {
                return bubble;
            }
        }
        return null;
    }

    @VisibleForTesting(visibility = PRIVATE)
    Bubble getOverflowBubbleWithKey(String key) {
        for (int i = 0; i < mOverflowBubbles.size(); i++) {
Loading