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

Commit 013adabd authored by Ats Jenk's avatar Ats Jenk
Browse files

Inflate handle view as part of expanded view layout

We need an id for the handle view so that we can reference it in the
integration.
Move inflation of the handle view from the expanded view class to the
layout. This allows us to specify a resource id for it.

Bug: 283991264
Test: open a bubble from bubble bar
Test: atest PlatformScenarioTests:android.platform.test.scenario.sysui.bubble.BubbleBarTest
Change-Id: I55319b989bf953c8c4f856242d1ca4abdf8ede1b
parent a5813cbe
Loading
Loading
Loading
Loading
+5 −0
Original line number Diff line number Diff line
@@ -21,4 +21,9 @@
    android:orientation="vertical"
    android:id="@+id/bubble_bar_expanded_view">

    <com.android.wm.shell.bubbles.bar.BubbleBarHandleView
        android:id="@+id/bubble_bar_handle_view"
        android:layout_height="wrap_content"
        android:layout_width="wrap_content" />

</com.android.wm.shell.bubbles.bar.BubbleBarExpandedView>
+2 −2
Original line number Diff line number Diff line
@@ -70,7 +70,7 @@ public class BubbleBarExpandedView extends FrameLayout implements BubbleTaskView
    private @Nullable Supplier<Rect> mLayerBoundsSupplier;
    private @Nullable Listener mListener;

    private BubbleBarHandleView mHandleView = new BubbleBarHandleView(getContext());
    private BubbleBarHandleView mHandleView;
    private @Nullable TaskView mTaskView;
    private @Nullable BubbleOverflowContainerView mOverflowView;

@@ -111,7 +111,7 @@ public class BubbleBarExpandedView extends FrameLayout implements BubbleTaskView
        setElevation(getResources().getDimensionPixelSize(R.dimen.bubble_elevation));
        mCaptionHeight = context.getResources().getDimensionPixelSize(
                R.dimen.bubble_bar_expanded_view_caption_height);
        addView(mHandleView);
        mHandleView = findViewById(R.id.bubble_bar_handle_view);
        applyThemeAttrs();
        setClipToOutline(true);
        setOutlineProvider(new ViewOutlineProvider() {