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

Commit 4f23ccd8 authored by Cecilia Hong's avatar Cecilia Hong Committed by Android (Google) Code Review
Browse files

Merge "Bubbles up the long-press event from media rec item to the parent card." into sc-qpr1-dev

parents 2cbc502f 4423e581
Loading
Loading
Loading
Loading
+10 −1
Original line number Diff line number Diff line
@@ -254,7 +254,8 @@ public class MediaControlPanel {
                openGuts();
                return true;
            } else {
                return false;
                closeGuts();
                return true;
            }
        });
        mRecommendationViewHolder.getCancel().setOnClickListener(v -> {
@@ -587,6 +588,14 @@ public class MediaControlPanel {
            ViewGroup mediaCoverContainer = mediaCoverContainers.get(uiComponentIndex);
            setSmartspaceRecItemOnClickListener(mediaCoverContainer, recommendation,
                    uiComponentIndex);
            // Bubble up the long-click event to the card.
            mediaCoverContainer.setOnLongClickListener(v -> {
                View parent = (View) v.getParent();
                if (parent != null) {
                    parent.performLongClick();
                }
                return true;
            });

            // Set up the accessibility label for the media item.
            String artistName = recommendation.getExtras()