Removed flvor checks. Added update settings under main settings.
This commit is contained in:
parent
6417bd91ef
commit
7124d9bca5
12 changed files with 107 additions and 36 deletions
9
app/src/main/res/drawable/ic_settings_update_black.xml
Normal file
9
app/src/main/res/drawable/ic_settings_update_black.xml
Normal file
|
|
@ -0,0 +1,9 @@
|
|||
<vector xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:width="24dp"
|
||||
android:height="24dp"
|
||||
android:viewportWidth="24.0"
|
||||
android:viewportHeight="24.0">
|
||||
<path
|
||||
android:fillColor="#FF000000"
|
||||
android:pathData="M19.35,10.04C18.67,6.59 15.64,4 12,4 9.11,4 6.6,5.64 5.35,8.04 2.34,8.36 0,10.91 0,14c0,3.31 2.69,6 6,6h13c2.76,0 5,-2.24 5,-5 0,-2.64 -2.05,-4.78 -4.65,-4.96zM17,13l-5,5 -5,-5h3V9h4v4h3z"/>
|
||||
</vector>
|
||||
5
app/src/main/res/drawable/ic_settings_update_white.xml
Normal file
5
app/src/main/res/drawable/ic_settings_update_white.xml
Normal file
|
|
@ -0,0 +1,5 @@
|
|||
<vector android:height="24dp" android:tint="#FFFFFF"
|
||||
android:viewportHeight="24.0" android:viewportWidth="24.0"
|
||||
android:width="24dp" xmlns:android="http://schemas.android.com/apk/res/android">
|
||||
<path android:fillColor="#FF000000" android:pathData="M19.35,10.04C18.67,6.59 15.64,4 12,4 9.11,4 6.6,5.64 5.35,8.04 2.34,8.36 0,10.91 0,14c0,3.31 2.69,6 6,6h13c2.76,0 5,-2.24 5,-5 0,-2.64 -2.05,-4.78 -4.65,-4.96zM17,13l-5,5 -5,-5h3V9h4v4h3z"/>
|
||||
</vector>
|
||||
|
|
@ -38,6 +38,7 @@
|
|||
<attr name="ic_add" format="reference"/>
|
||||
<attr name="ic_restore_defaults" format="reference"/>
|
||||
<attr name="ic_blank_page" format="reference"/>
|
||||
<attr name="ic_settings_update" format="reference"/>
|
||||
|
||||
<!-- Can't refer to colors directly in drawable's xml-->
|
||||
<attr name="toolbar_shadow_drawable" format="reference"/>
|
||||
|
|
|
|||
|
|
@ -201,6 +201,9 @@
|
|||
<item>@string/always_ask_open_action_key</item>
|
||||
</string-array>
|
||||
|
||||
<!-- Updates -->
|
||||
<string name="update_app_key" translatable="false">update_app_key</string>
|
||||
|
||||
<!-- alternatively, load these from some local android data store -->
|
||||
<string-array name="language_codes" translatable="false">
|
||||
<item>af</item>
|
||||
|
|
|
|||
|
|
@ -109,6 +109,7 @@
|
|||
<string name="settings_category_appearance_title">Appearance</string>
|
||||
<string name="settings_category_other_title">Other</string>
|
||||
<string name="settings_category_debug_title">Debug</string>
|
||||
<string name="settings_category_updates_title">Updates</string>
|
||||
<string name="background_player_playing_toast">Playing in background</string>
|
||||
<string name="popup_playing_toast">Playing in popup mode</string>
|
||||
<string name="background_player_append">Queued on background player</string>
|
||||
|
|
@ -515,6 +516,10 @@
|
|||
<item>144p</item>
|
||||
</string-array>
|
||||
|
||||
<!-- Updates Settings -->
|
||||
<string name="updates_setting_title">Updates</string>
|
||||
<string name="updates_setting_description"> Show a notification to prompt app update when a new version is available</string>
|
||||
|
||||
<!-- Minimize to exit action -->
|
||||
<string name="minimize_on_exit_title">Minimize on application switch</string>
|
||||
<string name="minimize_on_exit_summary">Action when switching to other application from main video player — %s</string>
|
||||
|
|
@ -526,8 +531,4 @@
|
|||
<string name="app_update_notification_content_title">NewPipe Update Available</string>
|
||||
<string name="app_update_notification_content_text">Tap to download</string>
|
||||
|
||||
<!-- Flavor names -->
|
||||
<string name="app_flavor_github">github</string>
|
||||
<string name="app_flavor_fdroid">fdroid</string>
|
||||
|
||||
</resources>
|
||||
|
|
|
|||
|
|
@ -54,6 +54,7 @@
|
|||
<item name="ic_add">@drawable/ic_add_black_24dp</item>
|
||||
<item name="ic_restore_defaults">@drawable/ic_settings_backup_restore_black_24dp</item>
|
||||
<item name="ic_blank_page">@drawable/ic_blank_page_black_24dp</item>
|
||||
<item name="ic_settings_update">@drawable/ic_settings_update_black</item>
|
||||
|
||||
<item name="separator_color">@color/light_separator_color</item>
|
||||
<item name="contrast_background_color">@color/light_contrast_background_color</item>
|
||||
|
|
@ -114,6 +115,7 @@
|
|||
<item name="ic_add">@drawable/ic_add_white_24dp</item>
|
||||
<item name="ic_restore_defaults">@drawable/ic_settings_backup_restore_white_24dp</item>
|
||||
<item name="ic_blank_page">@drawable/ic_blank_page_white_24dp</item>
|
||||
<item name="ic_settings_update">@drawable/ic_settings_update_white</item>
|
||||
|
||||
<item name="separator_color">@color/dark_separator_color</item>
|
||||
<item name="contrast_background_color">@color/dark_contrast_background_color</item>
|
||||
|
|
|
|||
|
|
@ -29,6 +29,11 @@
|
|||
android:icon="?attr/language"
|
||||
android:title="@string/content"/>
|
||||
|
||||
<PreferenceScreen
|
||||
android:fragment="org.schabi.newpipe.settings.UpdateSettingsFragment"
|
||||
android:icon="?attr/ic_settings_update"
|
||||
android:title="@string/settings_category_updates_title" />
|
||||
|
||||
<PreferenceScreen
|
||||
android:fragment="org.schabi.newpipe.settings.DebugSettingsFragment"
|
||||
android:icon="?attr/bug"
|
||||
|
|
|
|||
13
app/src/main/res/xml/update_settings.xml
Normal file
13
app/src/main/res/xml/update_settings.xml
Normal file
|
|
@ -0,0 +1,13 @@
|
|||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<PreferenceScreen
|
||||
xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:key="general_preferences"
|
||||
android:title="@string/settings_category_updates_title">
|
||||
|
||||
<SwitchPreference
|
||||
android:defaultValue="true"
|
||||
android:key="@string/update_app_key"
|
||||
android:title="@string/updates_setting_title"
|
||||
android:summary="@string/updates_setting_description"/>
|
||||
|
||||
</PreferenceScreen>
|
||||
Loading…
Add table
Add a link
Reference in a new issue