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

Commit 77f21a8d authored by Treehugger Robot's avatar Treehugger Robot Committed by Gerrit Code Review
Browse files

Merge "Use SwitchPreferenceCompat for UI consistency" into main

parents b384fe70 602cec99
Loading
Loading
Loading
Loading
+2 −3
Original line number Diff line number Diff line
@@ -114,11 +114,10 @@
            android:summary="@string/oem_unlock_enable_summary"
            settings:useAdditionalSummary="true" />

        <SwitchPreference
        <SwitchPreferenceCompat
            android:key="enable_16k_pages"
            android:title="@string/enable_16k_pages"
            android:summary="@string/enable_16k_pages_summary"
            settings:useAdditionalSummary="true" />
            android:summary="@string/enable_16k_pages_summary"/>

        <Preference
            android:key="running_apps"
+3 −3
Original line number Diff line number Diff line
@@ -39,7 +39,7 @@ import androidx.annotation.VisibleForTesting;
import androidx.appcompat.app.AlertDialog;
import androidx.core.content.ContextCompat;
import androidx.preference.Preference;
import androidx.preference.SwitchPreference;
import androidx.preference.SwitchPreferenceCompat;

import com.android.settings.R;
import com.android.settings.core.PreferenceControllerMixin;
@@ -139,7 +139,7 @@ public class Enable16kPagesPreferenceController extends DeveloperOptionsPreferen
                        Settings.Global.ENABLE_16K_PAGES,
                        defaultOptionValue /* default */);

        ((SwitchPreference) mPreference).setChecked(optionValue == ENABLE_16K_PAGE_SIZE);
        ((SwitchPreferenceCompat) mPreference).setChecked(optionValue == ENABLE_16K_PAGE_SIZE);
    }

    @Override
@@ -150,7 +150,7 @@ public class Enable16kPagesPreferenceController extends DeveloperOptionsPreferen
                mContext.getContentResolver(),
                Settings.Global.ENABLE_16K_PAGES,
                ENABLE_4K_PAGE_SIZE);
        ((SwitchPreference) mPreference).setChecked(false);
        ((SwitchPreferenceCompat) mPreference).setChecked(false);
    }

    @Override