Skip to content

Commit

Permalink
[Side Sheet] Changed side sheet child containers in Catalog from Line…
Browse files Browse the repository at this point in the history
…arLayouts to FrameLayouts.

The LinearLayouts each contained only one child, so a FrameLayout is a better choice; more lightweight and slightly more performant. This is a visual no-op.

PiperOrigin-RevId: 532823326
  • Loading branch information
afohrman authored and imhappi committed May 22, 2023
1 parent a0d4fa0 commit 690cd5d
Showing 1 changed file with 10 additions and 10 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@
<merge xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:app="http://schemas.android.com/apk/res-auto"
xmlns:tools="http://schemas.android.com/tools">
<LinearLayout
<FrameLayout
android:id="@+id/standard_side_sheet_container"
style="@style/Widget.Material3.SideSheet"
android:layout_width="256dp"
Expand All @@ -25,9 +25,9 @@
app:layout_behavior="@string/side_sheet_behavior"
tools:targetApi="lollipop">
<include layout="@layout/cat_sidesheet_content" />
</LinearLayout>
</FrameLayout>

<LinearLayout
<FrameLayout
android:id="@+id/standard_detached_side_sheet_container"
style="@style/Widget.Material3.SideSheet.Detached"
android:layout_width="256dp"
Expand All @@ -36,9 +36,9 @@
app:layout_behavior="@string/side_sheet_behavior"
tools:targetApi="lollipop">
<include layout="@layout/cat_sidesheet_detached_content" />
</LinearLayout>
</FrameLayout>

<LinearLayout
<FrameLayout
android:id="@+id/vertically_scrolling_side_sheet_container"
style="@style/Widget.Material3.SideSheet"
android:layout_width="256dp"
Expand All @@ -47,9 +47,9 @@
app:layout_behavior="@string/side_sheet_behavior"
tools:targetApi="lollipop">
<include layout="@layout/cat_sidesheet_content_vertically_scrolling" />
</LinearLayout>
</FrameLayout>

<LinearLayout
<FrameLayout
android:id="@+id/coplanar_side_sheet_container"
style="@style/Widget.Material3.SideSheet"
android:layout_width="256dp"
Expand All @@ -59,9 +59,9 @@
app:layout_behavior="@string/side_sheet_behavior"
tools:targetApi="lollipop">
<include layout="@layout/cat_sidesheet_content_coplanar" />
</LinearLayout>
</FrameLayout>

<LinearLayout
<FrameLayout
android:id="@+id/coplanar_detached_side_sheet_container"
style="@style/Widget.Material3.SideSheet.Detached"
android:layout_width="256dp"
Expand All @@ -71,5 +71,5 @@
app:layout_behavior="@string/side_sheet_behavior"
tools:targetApi="lollipop">
<include layout="@layout/cat_sidesheet_content_coplanar_detached" />
</LinearLayout>
</FrameLayout>
</merge>

0 comments on commit 690cd5d

Please sign in to comment.