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

Commit dcc9bfb8 authored by Santiago Etchebehere's avatar Santiago Etchebehere
Browse files

Landscape support 1/n

Correct layout of theme/clock/grid picker fragment,
theme preview cards and custom theme still missing.

Bug: 125903559
Change-Id: Ibdfe9d9c5a6ad22039ec5581764990d7c775c8d5
parent 16020ba2
Loading
Loading
Loading
Loading
+68 −0
Original line number Diff line number Diff line
<?xml version="1.0" encoding="utf-8"?>
<!--
     Copyright (C) 2019 The Android Open Source Project

     Licensed under the Apache License, Version 2.0 (the "License");
     you may not use this file except in compliance with the License.
     You may obtain a copy of the License at

          http://www.apache.org/licenses/LICENSE-2.0

     Unless required by applicable law or agreed to in writing, software
     distributed under the License is distributed on an "AS IS" BASIS,
     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     See the License for the specific language governing permissions and
     limitations under the License.
-->
<LinearLayout
    xmlns:android="http://schemas.android.com/apk/res/android"
    xmlns:app="http://schemas.android.com/apk/res-auto"
    android:layout_width="match_parent"
    android:layout_height="match_parent"
    android:orientation="vertical"
    android:background="?android:colorPrimary">
    <include layout="@layout/section_header"/>

    <LinearLayout
        android:layout_width="match_parent"
        android:layout_height="match_parent"
        android:orientation="horizontal">

        <com.android.customization.widget.PreviewPager
            android:id="@+id/clock_preview_pager"
            android:layout_width="0dp"
            android:layout_height="match_parent"
            android:layout_weight="1"
            android:background="@color/secondary_color"
            app:card_style="screen_aspect_ratio"/>

        <LinearLayout
            android:id="@+id/options_section"
            android:layout_width="0dp"
            android:layout_height="match_parent"
            android:layout_weight="1"
            android:paddingVertical="10dp"
            android:orientation="vertical">

            <androidx.recyclerview.widget.RecyclerView
                android:id="@+id/options_container"
                android:layout_width="match_parent"
                android:layout_height="0dp"
                android:layout_weight="1"/>

            <RelativeLayout
                android:layout_width="match_parent"
                android:layout_height="wrap_content"
                android:paddingHorizontal="10dp">
                <Button
                    android:id="@+id/apply_button"
                    style="@style/ActionPrimaryButton"
                    android:layout_width="wrap_content"
                    android:layout_height="wrap_content"
                    android:layout_alignParentEnd="true"
                    android:text="@string/apply_btn"/>
            </RelativeLayout>

        </LinearLayout>
    </LinearLayout>
</LinearLayout>
+65 −0
Original line number Diff line number Diff line
<?xml version="1.0" encoding="utf-8"?>
<!--
     Copyright (C) 2019 The Android Open Source Project

     Licensed under the Apache License, Version 2.0 (the "License");
     you may not use this file except in compliance with the License.
     You may obtain a copy of the License at

          http://www.apache.org/licenses/LICENSE-2.0

     Unless required by applicable law or agreed to in writing, software
     distributed under the License is distributed on an "AS IS" BASIS,
     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     See the License for the specific language governing permissions and
     limitations under the License.
-->
<LinearLayout
    xmlns:android="http://schemas.android.com/apk/res/android"
    android:layout_width="match_parent"
    android:layout_height="match_parent" xmlns:app="http://schemas.android.com/apk/res-auto"
    android:orientation="vertical"
    android:background="?android:colorPrimary">
    <include layout="@layout/section_header"/>
    <LinearLayout
        android:layout_width="match_parent"
        android:layout_height="match_parent"
        android:orientation="horizontal">
        <com.android.customization.widget.PreviewPager
            android:id="@+id/grid_preview_pager"
            android:layout_width="0dp"
            android:layout_height="match_parent"
            android:layout_weight="1"
            android:background="@color/secondary_color"
            app:card_style="screen_aspect_ratio"/>

        <LinearLayout
            android:id="@+id/options_section"
            android:layout_width="0dp"
            android:layout_height="match_parent"
            android:layout_weight="1"
            android:paddingVertical="10dp"
            android:orientation="vertical">

            <androidx.recyclerview.widget.RecyclerView
                android:id="@+id/options_container"
                android:layout_width="match_parent"
                android:layout_height="0dp"
                android:layout_weight="1"/>

            <RelativeLayout
                android:layout_width="match_parent"
                android:layout_height="wrap_content"
                android:paddingHorizontal="10dp">
                <Button
                    android:id="@+id/apply_button"
                    style="@style/ActionPrimaryButton"
                    android:layout_width="wrap_content"
                    android:layout_height="wrap_content"
                    android:layout_alignParentEnd="true"
                    android:text="@string/apply_btn"/>
            </RelativeLayout>

        </LinearLayout>
    </LinearLayout>
</LinearLayout>
+74 −0
Original line number Diff line number Diff line
<?xml version="1.0" encoding="utf-8"?>
<!--
     Copyright (C) 2019 The Android Open Source Project

     Licensed under the Apache License, Version 2.0 (the "License");
     you may not use this file except in compliance with the License.
     You may obtain a copy of the License at

          http://www.apache.org/licenses/LICENSE-2.0

     Unless required by applicable law or agreed to in writing, software
     distributed under the License is distributed on an "AS IS" BASIS,
     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     See the License for the specific language governing permissions and
     limitations under the License.
-->
<LinearLayout
    xmlns:android="http://schemas.android.com/apk/res/android"
    android:layout_width="match_parent"
    android:layout_height="match_parent"
    android:orientation="vertical"
    android:background="?android:colorPrimary">
    <include layout="@layout/section_header"/>

    <LinearLayout
        android:layout_width="match_parent"
        android:layout_height="match_parent"
        android:orientation="horizontal">

        <com.android.customization.widget.PreviewPager
            android:id="@+id/theme_preview_pager"
            android:layout_width="0dp"
            android:layout_height="match_parent"
            android:layout_weight="1"
            android:background="@color/secondary_color"/>

        <LinearLayout
            android:id="@+id/options_section"
            android:layout_width="0dp"
            android:layout_height="match_parent"
            android:layout_weight="1"
            android:paddingVertical="10dp"
            android:orientation="vertical">

            <androidx.recyclerview.widget.RecyclerView
                android:id="@+id/options_container"
                android:layout_width="match_parent"
                android:layout_height="0dp"
                android:layout_weight="1"/>

            <RelativeLayout
                android:layout_width="match_parent"
                android:layout_height="wrap_content"
                android:paddingHorizontal="10dp">
                <CheckBox
                    android:id="@+id/use_my_wallpaper"
                    android:layout_width="wrap_content"
                    android:layout_height="wrap_content"
                    android:layout_alignParentStart="true"
                    android:layout_centerVertical="true"
                    android:paddingLeft="4dp"
                    android:minHeight="@dimen/min_taptarget_height"
                    android:text="@string/keep_my_wallpaper"/>
                <Button
                    android:id="@+id/apply_button"
                    style="@style/ActionPrimaryButton"
                    android:layout_width="wrap_content"
                    android:layout_height="wrap_content"
                    android:layout_alignParentEnd="true"
                    android:text="@string/apply_theme_btn"/>
            </RelativeLayout>
        </LinearLayout>
    </LinearLayout>
</LinearLayout>
+3 −1
Original line number Diff line number Diff line
@@ -16,7 +16,9 @@
-->
<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:paddingRight="2dp"
    android:paddingBottom="@dimen/option_bottom_margin"
    android:orientation="vertical">

    <TextView
+3 −1
Original line number Diff line number Diff line
@@ -16,7 +16,9 @@
-->
<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:paddingRight="2dp"
    android:paddingBottom="@dimen/option_bottom_margin"
    android:orientation="vertical">

    <TextView
Loading