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

Commit 84baab38 authored by Michael W's avatar Michael W
Browse files

ThemePicker: Fixes to improve layout

* In order to bring the layout inline with the looks of the 18.1 branch
  we need to modify a few files with content from commits that don't
  apply without changing too much of the code in both ThemePicker and
  WallpaperPicker2
* Therefore define missing dimensions and apply parts of code we need
  to make it look good
* Make the header single line in the preview so a name gets cut instead
  of shifting the whole content of the tile down
* Give the preview_top_bar a margin so in the preview page it's not
  glued to the top
* Change the background of the naming page to primaryColor as well
  -> Add the same divider as on other pages as well
* Don't forget the landscape layouts!

Change-Id: I4f8ae1968d6361f54fd71f4d00fc0d706f21e124
parent a47a04b3
Loading
Loading
Loading
Loading
+6 −1
Original line number Diff line number Diff line
@@ -38,9 +38,14 @@
                android:layout_width="0dp"
                android:layout_height="match_parent"
                android:layout_weight="1"
                android:background="@color/secondary_color"
                android:background="@color/preview_pager_background"
                app:card_style="screen_aspect_ratio"/>

            <View
                android:layout_width="1dp"
                android:layout_height="match_parent"
                android:background="@color/divider_color"/>

            <LinearLayout
                android:id="@+id/options_section"
                android:layout_width="0dp"
+9 −1
Original line number Diff line number Diff line
@@ -31,7 +31,7 @@
            android:layout_width="0dp"
            android:layout_height="match_parent"
            android:layout_weight="1"
            android:background="@color/secondary_color">
            android:background="?android:colorPrimary">
            <include
                android:id="@+id/component_preview_content"
                android:layout_width="match_parent"
@@ -41,6 +41,12 @@
                android:layout_marginBottom="@dimen/component_preview_page_bottom_margin"
                layout="@layout/theme_preview_card"/>
        </FrameLayout>

        <View
            android:layout_width="1dp"
            android:layout_height="match_parent"
            android:background="@color/divider_color"/>

        <LinearLayout
            android:id="@+id/options_section"
            android:layout_width="0dp"
@@ -71,6 +77,8 @@
                    android:id="@+id/custom_theme_name"
                    android:layout_width="wrap_content"
                    android:layout_height="wrap_content"
                    android:layout_marginVertical="16dp"
                    android:layout_marginHorizontal="16dp"
                    android:layout_gravity="center"
                    android:minWidth="300dp"/>
            </FrameLayout>
+6 −1
Original line number Diff line number Diff line
@@ -36,9 +36,14 @@
            android:layout_width="0dp"
            android:layout_height="match_parent"
            android:layout_weight="1"
            android:background="@color/secondary_color"
            android:background="@color/preview_pager_background"
            app:card_style="screen_aspect_ratio"/>

        <View
            android:layout_width="1dp"
            android:layout_height="match_parent"
            android:background="@color/divider_color"/>

        <LinearLayout
            android:id="@+id/options_section"
            android:layout_width="0dp"
+1 −1
Original line number Diff line number Diff line
@@ -36,7 +36,7 @@
                android:layout_width="0dp"
                android:layout_height="match_parent"
                android:layout_weight="1"
                android:background="@color/secondary_color"/>
                android:background="@color/preview_pager_background"/>
            <View
                android:layout_width="1dp"
                android:layout_height="match_parent"
+9 −2
Original line number Diff line number Diff line
@@ -16,15 +16,22 @@
-->
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
    android:layout_width="wrap_content"
    android:layout_height="match_parent"
    android:layout_height="wrap_content"
    android:paddingHorizontal="@dimen/option_padding_horizontal"
    android:paddingBottom="@dimen/option_bottom_margin"
    android:clipChildren="false"
    android:clipToPadding="false"
    android:orientation="vertical">

    <TextView
        android:id="@+id/option_label"
        android:layout_width="wrap_content"
        android:layout_width="@dimen/option_tile_width"
        android:layout_height="wrap_content"
        android:layout_gravity="center_horizontal"
        android:layout_marginBottom="@dimen/theme_option_label_margin"
        android:ellipsize="end"
        android:gravity="center_horizontal"
        android:maxLines="1"
        android:textAppearance="@style/OptionTitleTextAppearance"/>
    <FrameLayout
        android:id="@+id/option_tile"
Loading