diff --git a/res/values/cherish_arrays.xml b/res/values/cherish_arrays.xml index ed058b9..3228703 100644 --- a/res/values/cherish_arrays.xml +++ b/res/values/cherish_arrays.xml @@ -1156,4 +1156,47 @@ 6 7 + + + + @string/qstile_default + @string/qstile_circle_trim + @string/qstile_dual_tone_circle + @string/qstile_squircle_trim + @string/qstile_wavey + @string/qstile_pokesign + @string/qstile_ninja + @string/qstile_dottedcircle + @string/qstile_attemptmountain + @string/qstile_squaremedo + @string/qstile_inkdrop + @string/qstile_cookie + @string/qstile_circleoutline + @string/qstile_cosmos + @string/qstile_divided + @string/qstile_neonlike + @string/qstile_oos + @string/qstile_triangles + + + + 0 + 1 + 2 + 3 + 4 + 5 + 6 + 7 + 8 + 9 + 10 + 11 + 12 + 13 + 14 + 15 + 16 + 17 + diff --git a/res/values/cherish_strings.xml b/res/values/cherish_strings.xml index 3a61b37..2e78f75 100644 --- a/res/values/cherish_strings.xml +++ b/res/values/cherish_strings.xml @@ -1061,4 +1061,25 @@ Retro Telegram Stockish + + + QS tile style + Default + Circle with trim + Dual-toned circle + Squircle with trim + Wavey + Pokesign + Ninja + Dotted Circle + An attempt of a mountain + The Squaremedo + Ink + Cookie + Circle Outline + Shishu Cosmos + Divided Circle + Neon Light + Oxygen + Triangle diff --git a/res/xml/cherish_settings_theme.xml b/res/xml/cherish_settings_theme.xml index 928b5c6..5ba738b 100644 --- a/res/xml/cherish_settings_theme.xml +++ b/res/xml/cherish_settings_theme.xml @@ -65,7 +65,15 @@ android:entryValues="@array/switch_style_values" android:summary="%s" android:defaultValue="0" /> - + + + = 0 ? valueIndex : 0); + mQsTileStyle.setSummary(mQsTileStyle.getEntry()); + mQsTileStyle.setOnPreferenceChangeListener(this); + mUiModeManager = getContext().getSystemService(UiModeManager.class); mOverlayService = IOverlayManager.Stub @@ -308,6 +318,11 @@ public class ThemeSettings extends SettingsPreferenceFragment implements Settings.System.QS_HEADER_STYLE, Integer.valueOf(value)); int newIndex = mQsHeaderStyle.findIndexOfValue(value); mQsHeaderStyle.setSummary(mQsHeaderStyle.getEntries()[newIndex]); + } else if (preference == mQsTileStyle) { + int qsTileStyleValue = Integer.valueOf((String) objValue); + Settings.System.putIntForUser(resolver, + Settings.System.QS_TILE_STYLE, qsTileStyleValue, UserHandle.USER_CURRENT); + mQsTileStyle.setSummary(mQsTileStyle.getEntries()[qsTileStyleValue]); } return true; }