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

Commit 30f967f9 authored by Beth Thibodeau's avatar Beth Thibodeau Committed by Android (Google) Code Review
Browse files

Merge "Fix media vertical cut off in scene container" into main

parents 0e375753 68c52490
Loading
Loading
Loading
Loading
+5 −0
Original line number Diff line number Diff line
@@ -53,6 +53,11 @@ fun SceneScope.MediaCarousel(
                val mediaFrame = carouselController.mediaFrame
                (mediaFrame.parent as? ViewGroup)?.removeView(mediaFrame)
                addView(mediaFrame)
                layoutParams =
                    FrameLayout.LayoutParams(
                        FrameLayout.LayoutParams.MATCH_PARENT,
                        FrameLayout.LayoutParams.MATCH_PARENT,
                    )
            }
        },
        update = {
+2 −2
Original line number Diff line number Diff line
@@ -19,7 +19,7 @@
<FrameLayout
    xmlns:android="http://schemas.android.com/apk/res/android"
    android:layout_width="match_parent"
    android:layout_height="wrap_content"
    android:layout_height="match_parent"
    android:clipChildren="false"
    android:clipToPadding="false"
    android:forceHasOverlappingRendering="false"
@@ -27,7 +27,7 @@
    <com.android.systemui.media.controls.ui.view.MediaScrollView
        android:id="@+id/media_carousel_scroller"
        android:layout_width="match_parent"
        android:layout_height="wrap_content"
        android:layout_height="match_parent"
        android:scrollbars="none"
        android:clipChildren="false"
        android:clipToPadding="false"
+6 −0
Original line number Diff line number Diff line
@@ -656,8 +656,14 @@ constructor(
        if (width == widthInSceneContainerPx && height == heightInSceneContainerPx) {
            return
        }
        if (width <= 0 || height <= 0) {
            // reject as invalid
            return
        }
        widthInSceneContainerPx = width
        heightInSceneContainerPx = height
        mediaCarouselScrollHandler.playerWidthPlusPadding =
            width + context.resources.getDimensionPixelSize(R.dimen.qs_media_padding)
        updatePlayers(recreateMedia = true)
    }