Fix crashes of the interface in legacy Android versions
Co-authored-by: Marvin W <git@larma.de>
This commit is contained in:
parent
b43a8ba4e8
commit
51cd60078e
6 changed files with 14 additions and 27 deletions
|
|
@ -0,0 +1,14 @@
|
|||
<?xml version="1.0" encoding="utf-8"?><!--
|
||||
~ SPDX-FileCopyrightText: 2024 microG Project Team
|
||||
~ SPDX-License-Identifier: Apache-2.0
|
||||
-->
|
||||
|
||||
<ripple xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:color="?attr/colorControlHighlight">
|
||||
<item>
|
||||
<shape android:shape="rectangle">
|
||||
<solid android:color="?attr/colorSecondaryContainer"/>
|
||||
<corners android:radius="28dp"/>
|
||||
</shape>
|
||||
</item>
|
||||
</ripple>
|
||||
|
|
@ -0,0 +1,14 @@
|
|||
<?xml version="1.0" encoding="utf-8"?><!--
|
||||
~ SPDX-FileCopyrightText: 2024 microG Project Team
|
||||
~ SPDX-License-Identifier: Apache-2.0
|
||||
-->
|
||||
|
||||
<ripple xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:color="?attr/colorControlHighlight">
|
||||
<item>
|
||||
<shape android:shape="rectangle">
|
||||
<solid android:color="?attr/colorSurfaceContainer"/>
|
||||
<corners android:radius="28dp"/>
|
||||
</shape>
|
||||
</item>
|
||||
</ripple>
|
||||
|
|
@ -1,9 +0,0 @@
|
|||
<?xml version="1.0" encoding="utf-8"?><!--
|
||||
~ SPDX-FileCopyrightText: 2024 microG Project Team
|
||||
~ SPDX-License-Identifier: Apache-2.0
|
||||
-->
|
||||
|
||||
<shape xmlns:android="http://schemas.android.com/apk/res/android">
|
||||
<solid android:color="?attr/colorSecondaryContainer"/>
|
||||
<corners android:radius="28dp"/>
|
||||
</shape>
|
||||
|
|
@ -1,9 +0,0 @@
|
|||
<?xml version="1.0" encoding="utf-8"?><!--
|
||||
~ SPDX-FileCopyrightText: 2024 microG Project Team
|
||||
~ SPDX-License-Identifier: Apache-2.0
|
||||
-->
|
||||
|
||||
<shape xmlns:android="http://schemas.android.com/apk/res/android">
|
||||
<solid android:color="?attr/colorSurfaceContainer"/>
|
||||
<corners android:radius="28dp"/>
|
||||
</shape>
|
||||
|
|
@ -8,4 +8,18 @@
|
|||
<item name="android:statusBarColor">@android:color/transparent</item>
|
||||
<item name="android:windowLightStatusBar">false</item>
|
||||
</style>
|
||||
|
||||
<!-- Preference theme -->
|
||||
<style name="Theme.Base.PreferenceThemeOverlay" parent="@style/PreferenceThemeOverlay">
|
||||
<item name="switchPreferenceCompatStyle">@style/Theme.Base.Preference.SwitchPreferenceCompat</item>
|
||||
<item name="switchBarPreferenceStyle">@style/Theme.Base.Preference.SwitchBarPreference</item>
|
||||
</style>
|
||||
|
||||
<style name="Theme.Base.Preference.SwitchBarPreference" parent="@style/Preference.SwitchBar">
|
||||
<item name="layout">@layout/preference_material_switch_bar</item>
|
||||
<item name="switchBarFrameId">@id/frame</item>
|
||||
<item name="switchBarFrameBackgroundOn">@drawable/material_switch_bar_background</item>
|
||||
<item name="switchBarFrameBackgroundOff">@drawable/material_switch_bar_background</item>
|
||||
<item name="switchBarFrameBackgroundDisabled">@drawable/material_switch_bar_background_disabled</item>
|
||||
</style>
|
||||
</resources>
|
||||
|
|
|
|||
|
|
@ -39,21 +39,12 @@
|
|||
<!-- Preference theme -->
|
||||
<style name="Theme.Base.PreferenceThemeOverlay" parent="@style/PreferenceThemeOverlay">
|
||||
<item name="switchPreferenceCompatStyle">@style/Theme.Base.Preference.SwitchPreferenceCompat</item>
|
||||
<item name="switchBarPreferenceStyle">@style/Theme.Base.Preference.SwitchBarPreference</item>
|
||||
</style>
|
||||
|
||||
<style name="Theme.Base.Preference.SwitchPreferenceCompat" parent="@style/Preference.SwitchPreferenceCompat.Material">
|
||||
<item name="widgetLayout">@layout/preference_material_switch</item>
|
||||
</style>
|
||||
|
||||
<style name="Theme.Base.Preference.SwitchBarPreference" parent="@style/Preference.SwitchBar">
|
||||
<item name="layout">@layout/preference_material_switch_bar</item>
|
||||
<item name="switchBarFrameId">@id/frame</item>
|
||||
<item name="switchBarFrameBackgroundOn">@drawable/material_switch_bar_background</item>
|
||||
<item name="switchBarFrameBackgroundOff">@drawable/material_switch_bar_background</item>
|
||||
<item name="switchBarFrameBackgroundDisabled">@drawable/material_switch_bar_background_disabled</item>
|
||||
</style>
|
||||
|
||||
<!-- Application theme (< API23) -->
|
||||
<style name="Theme.App" parent="Theme.Base.DayNight.NoActionBar">
|
||||
<item name="colorPrimary">@color/gm3_ref_palette_primary40</item>
|
||||
|
|
|
|||
Loading…
Reference in a new issue