Make custom theme bottom IU vertical scrollable
- Make custom theme flow's bootom layout vertical scrollable when out of space (like set Display size and Font size to Largest)
video: https://drive.google.com/file/d/1wqq6qHdw6J4z9UCcThbMcn5bFHospMBw/view?usp=sharing
Fixes: 156987064
Test: manually
Change-Id: Ia6695147e00e2bfe3c017d7bf02e3b5127095fdc
diff --git a/res/layout/fragment_custom_theme_component.xml b/res/layout/fragment_custom_theme_component.xml
index fb3e5b3..26feab8 100644
--- a/res/layout/fragment_custom_theme_component.xml
+++ b/res/layout/fragment_custom_theme_component.xml
@@ -58,32 +58,39 @@
android:background="@color/divider_color"
app:layout_constraintEnd_toEndOf="parent"
app:layout_constraintStart_toStartOf="parent"
- app:layout_constraintTop_toBottomOf="@+id/component_preview_container"/>
-
- <TextView
- android:id="@+id/component_options_title"
- android:layout_width="match_parent"
- android:layout_height="wrap_content"
- android:layout_marginVertical="18dp"
- android:layout_marginHorizontal="16dp"
- android:textAlignment="center"
- android:textAppearance="@style/TitleTextAppearance"
- android:textSize="@dimen/component_options_title_size"
- app:layout_constraintEnd_toEndOf="parent"
- app:layout_constraintStart_toStartOf="parent"
app:layout_constraintTop_toBottomOf="@+id/component_preview_container"
- app:layout_constraintBottom_toTopOf="@+id/options_container"/>
+ app:layout_constraintBottom_toTopOf="@+id/component_scroll_view"/>
- <androidx.recyclerview.widget.RecyclerView
- android:id="@+id/options_container"
+ <ScrollView
+ android:id="@+id/component_scroll_view"
android:layout_width="match_parent"
android:layout_height="0dp"
- android:layout_gravity="center_horizontal"
- app:layout_constraintBottom_toBottomOf="parent"
app:layout_constraintEnd_toEndOf="parent"
app:layout_constraintStart_toStartOf="parent"
- app:layout_constraintTop_toBottomOf="@+id/component_options_title"
- app:layout_constraintVertical_bias="1"/>
+ app:layout_constraintTop_toBottomOf="@+id/divider"
+ app:layout_constraintBottom_toBottomOf="parent">
+ <LinearLayout
+ android:layout_width="match_parent"
+ android:layout_height="wrap_content"
+ android:orientation="vertical">
+
+ <TextView
+ android:id="@+id/component_options_title"
+ android:layout_width="match_parent"
+ android:layout_height="wrap_content"
+ android:layout_marginVertical="18dp"
+ android:layout_marginHorizontal="16dp"
+ android:textAlignment="center"
+ android:textAppearance="@style/TitleTextAppearance"
+ android:textSize="@dimen/component_options_title_size" />
+
+ <androidx.recyclerview.widget.RecyclerView
+ android:id="@+id/options_container"
+ android:layout_width="match_parent"
+ android:layout_height="wrap_content"
+ android:layout_gravity="center_horizontal"/>
+ </LinearLayout>
+ </ScrollView>
</androidx.constraintlayout.widget.ConstraintLayout>
</LinearLayout>