diff options
author | Alex Ning <chineseperson5@gmail.com> | 2020-11-30 16:12:16 +0000 |
---|---|---|
committer | Alex Ning <chineseperson5@gmail.com> | 2020-11-30 16:12:16 +0000 |
commit | 924128f09aa3c514bcbe74af65ad4feb05c774dc (patch) | |
tree | 7dd6bb841abfd4fd0cb09311aaccec16c57e46aa /app/src/main/res | |
parent | 4acf8611e72a3d25aff33f2fbaf3e5a10370aeec (diff) | |
download | infinity-for-reddit-924128f09aa3c514bcbe74af65ad4feb05c774dc.tar infinity-for-reddit-924128f09aa3c514bcbe74af65ad4feb05c774dc.tar.gz infinity-for-reddit-924128f09aa3c514bcbe74af65ad4feb05c774dc.tar.bz2 infinity-for-reddit-924128f09aa3c514bcbe74af65ad4feb05c774dc.tar.lz infinity-for-reddit-924128f09aa3c514bcbe74af65ad4feb05c774dc.tar.xz infinity-for-reddit-924128f09aa3c514bcbe74af65ad4feb05c774dc.tar.zst infinity-for-reddit-924128f09aa3c514bcbe74af65ad4feb05c774dc.zip |
Changing language is now available.
Diffstat (limited to 'app/src/main/res')
-rw-r--r-- | app/src/main/res/drawable-night/ic_language_24dp.xml | 9 | ||||
-rw-r--r-- | app/src/main/res/drawable/ic_language_24dp.xml | 9 | ||||
-rw-r--r-- | app/src/main/res/values/arrays.xml | 28 | ||||
-rw-r--r-- | app/src/main/res/values/strings.xml | 1 | ||||
-rw-r--r-- | app/src/main/res/xml/miscellaneous_preferences.xml | 9 |
5 files changed, 56 insertions, 0 deletions
diff --git a/app/src/main/res/drawable-night/ic_language_24dp.xml b/app/src/main/res/drawable-night/ic_language_24dp.xml new file mode 100644 index 00000000..e6e0586d --- /dev/null +++ b/app/src/main/res/drawable-night/ic_language_24dp.xml @@ -0,0 +1,9 @@ +<vector xmlns:android="http://schemas.android.com/apk/res/android" + android:width="24dp" + android:height="24dp" + android:viewportWidth="24" + android:viewportHeight="24"> + <path + android:fillColor="#FFFFFF" + android:pathData="M11.99,2C6.47,2 2,6.48 2,12s4.47,10 9.99,10C17.52,22 22,17.52 22,12S17.52,2 11.99,2zM18.92,8h-2.95c-0.32,-1.25 -0.78,-2.45 -1.38,-3.56 1.84,0.63 3.37,1.91 4.33,3.56zM12,4.04c0.83,1.2 1.48,2.53 1.91,3.96h-3.82c0.43,-1.43 1.08,-2.76 1.91,-3.96zM4.26,14C4.1,13.36 4,12.69 4,12s0.1,-1.36 0.26,-2h3.38c-0.08,0.66 -0.14,1.32 -0.14,2s0.06,1.34 0.14,2L4.26,14zM5.08,16h2.95c0.32,1.25 0.78,2.45 1.38,3.56 -1.84,-0.63 -3.37,-1.9 -4.33,-3.56zM8.03,8L5.08,8c0.96,-1.66 2.49,-2.93 4.33,-3.56C8.81,5.55 8.35,6.75 8.03,8zM12,19.96c-0.83,-1.2 -1.48,-2.53 -1.91,-3.96h3.82c-0.43,1.43 -1.08,2.76 -1.91,3.96zM14.34,14L9.66,14c-0.09,-0.66 -0.16,-1.32 -0.16,-2s0.07,-1.35 0.16,-2h4.68c0.09,0.65 0.16,1.32 0.16,2s-0.07,1.34 -0.16,2zM14.59,19.56c0.6,-1.11 1.06,-2.31 1.38,-3.56h2.95c-0.96,1.65 -2.49,2.93 -4.33,3.56zM16.36,14c0.08,-0.66 0.14,-1.32 0.14,-2s-0.06,-1.34 -0.14,-2h3.38c0.16,0.64 0.26,1.31 0.26,2s-0.1,1.36 -0.26,2h-3.38z"/> +</vector> diff --git a/app/src/main/res/drawable/ic_language_24dp.xml b/app/src/main/res/drawable/ic_language_24dp.xml new file mode 100644 index 00000000..b7840867 --- /dev/null +++ b/app/src/main/res/drawable/ic_language_24dp.xml @@ -0,0 +1,9 @@ +<vector xmlns:android="http://schemas.android.com/apk/res/android" + android:width="24dp" + android:height="24dp" + android:viewportWidth="24" + android:viewportHeight="24"> + <path + android:fillColor="#000000" + android:pathData="M11.99,2C6.47,2 2,6.48 2,12s4.47,10 9.99,10C17.52,22 22,17.52 22,12S17.52,2 11.99,2zM18.92,8h-2.95c-0.32,-1.25 -0.78,-2.45 -1.38,-3.56 1.84,0.63 3.37,1.91 4.33,3.56zM12,4.04c0.83,1.2 1.48,2.53 1.91,3.96h-3.82c0.43,-1.43 1.08,-2.76 1.91,-3.96zM4.26,14C4.1,13.36 4,12.69 4,12s0.1,-1.36 0.26,-2h3.38c-0.08,0.66 -0.14,1.32 -0.14,2s0.06,1.34 0.14,2L4.26,14zM5.08,16h2.95c0.32,1.25 0.78,2.45 1.38,3.56 -1.84,-0.63 -3.37,-1.9 -4.33,-3.56zM8.03,8L5.08,8c0.96,-1.66 2.49,-2.93 4.33,-3.56C8.81,5.55 8.35,6.75 8.03,8zM12,19.96c-0.83,-1.2 -1.48,-2.53 -1.91,-3.96h3.82c-0.43,1.43 -1.08,2.76 -1.91,3.96zM14.34,14L9.66,14c-0.09,-0.66 -0.16,-1.32 -0.16,-2s0.07,-1.35 0.16,-2h4.68c0.09,0.65 0.16,1.32 0.16,2s-0.07,1.34 -0.16,2zM14.59,19.56c0.6,-1.11 1.06,-2.31 1.38,-3.56h2.95c-0.96,1.65 -2.49,2.93 -4.33,3.56zM16.36,14c0.08,-0.66 0.14,-1.32 0.14,-2s-0.06,-1.34 -0.14,-2h3.38c0.16,0.64 0.26,1.31 0.26,2s-0.1,1.36 -0.26,2h-3.38z"/> +</vector> diff --git a/app/src/main/res/values/arrays.xml b/app/src/main/res/values/arrays.xml index 767e2fb9..37228db4 100644 --- a/app/src/main/res/values/arrays.xml +++ b/app/src/main/res/values/arrays.xml @@ -295,4 +295,32 @@ <item>1</item> </string-array> + <string-array name="settings_language"> + <item>Auto</item> + <item>Hrvatski</item> + <item>English</item> + <item>Française</item> + <item>Deutsche</item> + <item>हिंदी</item> + <item>Italiana</item> + <item>日本語</item> + <item>Português (BR)</item> + <item>Español</item> + <item>Türkçe</item> + </string-array> + + <string-array name="settings_language_values"> + <item>auto</item> + <item>hr</item> + <item>en</item> + <item>fr</item> + <item>de</item> + <item>hi</item> + <item>it</item> + <item>ja</item> + <item>pt-rBR</item> + <item>es</item> + <item>tr-rTR</item> + </string-array> + </resources>
\ No newline at end of file diff --git a/app/src/main/res/values/strings.xml b/app/src/main/res/values/strings.xml index fa386470..eac39901 100644 --- a/app/src/main/res/values/strings.xml +++ b/app/src/main/res/values/strings.xml @@ -507,6 +507,7 @@ <string name="settings_swipe_action_swipe_left_title">Swipe Left</string> <string name="settings_swipe_action_swipe_right_title">Swipe Right</string> <string name="settings_swipe_action_info_summary">Not applicable to post feed with more than 1 column or post detail.</string> + <string name="settings_language_title">Language</string> <string name="no_link_available">Cannot get the link</string> diff --git a/app/src/main/res/xml/miscellaneous_preferences.xml b/app/src/main/res/xml/miscellaneous_preferences.xml index f4274a5a..95532c33 100644 --- a/app/src/main/res/xml/miscellaneous_preferences.xml +++ b/app/src/main/res/xml/miscellaneous_preferences.xml @@ -25,4 +25,13 @@ app:title="@string/settings_respect_subreddit_recommended_comment_sort_type_title" app:summary="@string/settings_respect_subreddit_recommended_comment_sort_type_summary" /> + <ListPreference + app:defaultValue="auto" + app:entries="@array/settings_language" + app:entryValues="@array/settings_language_values" + app:key="language" + app:icon="@drawable/ic_language_24dp" + app:title="@string/settings_language_title" + app:useSimpleSummaryProvider="true" /> + </PreferenceScreen>
\ No newline at end of file |