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

Unverified Commit 6e0e1f02 authored by Michael Bestas's avatar Michael Bestas
Browse files

Migrate long screen settings to MaterialSwitch

Change-Id: I0f83691b225e2119c91380f23379de96ad096d7b
parent 1997755e
Loading
Loading
Loading
Loading
+6 −3
Original line number Diff line number Diff line
<?xml version="1.0" encoding="utf-8"?>
<!--
     SPDX-FileCopyrightText: 2018 The LineageOS Project
     SPDX-FileCopyrightText: 2018-2024 The LineageOS Project
     SPDX-License-Identifier: Apache-2.0
-->
<LinearLayout
@@ -40,8 +40,11 @@

    </LinearLayout>

    <Switch
    <com.google.android.material.materialswitch.MaterialSwitch
        xmlns:android="http://schemas.android.com/apk/res/android"
        android:id="@+id/state"
        android:layout_width="wrap_content"
        android:layout_height="match_parent" />
        android:layout_height="wrap_content"
        android:background="@null"
        android:theme="@style/Theme.Material3.DynamicColors.DayNight" />
</LinearLayout>
+3 −3
Original line number Diff line number Diff line
/*
 * SPDX-FileCopyrightText: 2018-2023 The LineageOS Project
 * SPDX-FileCopyrightText: 2018-2024 The LineageOS Project
 * SPDX-License-Identifier: Apache-2.0
 */
package org.lineageos.lineageparts.applications;
@@ -20,12 +20,12 @@ import android.widget.BaseAdapter;
import android.widget.ImageView;
import android.widget.ListView;
import android.widget.SectionIndexer;
import android.widget.Switch;
import android.widget.TextView;

import androidx.annotation.NonNull;

import com.android.settingslib.applications.ApplicationsState;
import com.google.android.material.materialswitch.MaterialSwitch;

import org.lineageos.internal.applications.LongScreen;
import org.lineageos.lineageparts.R;
@@ -274,7 +274,7 @@ public class LongScreenSettings extends SettingsPreferenceFragment
    private static class ViewHolder {
        private final TextView title;
        private final ImageView icon;
        private final Switch state;
        private final MaterialSwitch state;
        private final View rootView;

        private ViewHolder(View view) {