Use SwitchMaterial for preferences too (closes #5724)

This commit is contained in:
arkon 2021-10-09 17:47:04 -04:00
parent c95a269460
commit aae011ed83
2 changed files with 17 additions and 3 deletions

View File

@ -0,0 +1,9 @@
<?xml version="1.0" encoding="utf-8"?>
<com.google.android.material.switchmaterial.SwitchMaterial
xmlns:android="http://schemas.android.com/apk/res/android"
android:id="@+id/switchWidget"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:focusable="false"
android:clickable="false"
android:background="@null"/>

View File

@ -297,11 +297,16 @@
<item name="android:windowExitAnimation">@anim/fade_out_short</item>
</style>
<!--==========-->
<!--Preference-->
<!--==========-->
<!--===========-->
<!--Preferences-->
<!--===========-->
<style name="PreferenceThemeOverlay.Tachiyomi">
<item name="preferenceCategoryTitleTextAppearance">?attr/textAppearanceBody2</item>
<item name="switchPreferenceCompatStyle">@style/PreferenceThemeOverlay.Tachiyomi.SwitchPreferenceCompat</item>
</style>
<style name="PreferenceThemeOverlay.Tachiyomi.SwitchPreferenceCompat" parent="Preference.SwitchPreferenceCompat.Material">
<item name="android:widgetLayout">@layout/pref_widget_switch_material</item>
</style>
</resources>