From 6fc91312d2083313ddca22baa07605432c53ac0a Mon Sep 17 00:00:00 2001 From: Avently <7953703+avently@users.noreply.github.com> Date: Thu, 9 Jan 2020 19:27:10 +0300 Subject: [PATCH] Changed default autoplay type to "Only on WiFi" --- .../org/schabi/newpipe/player/helper/PlayerHelper.java | 10 +++++----- app/src/main/res/values/settings_keys.xml | 2 +- 2 files changed, 6 insertions(+), 6 deletions(-) diff --git a/app/src/main/java/org/schabi/newpipe/player/helper/PlayerHelper.java b/app/src/main/java/org/schabi/newpipe/player/helper/PlayerHelper.java index 80f38afb2..a0152c13a 100644 --- a/app/src/main/java/org/schabi/newpipe/player/helper/PlayerHelper.java +++ b/app/src/main/java/org/schabi/newpipe/player/helper/PlayerHelper.java @@ -216,17 +216,17 @@ public class PlayerHelper { @AutoplayType public static int getAutoplayType(@NonNull final Context context) { - final String defaultType = context.getString(R.string.autoplay_always_key); - final String wifi = context.getString(R.string.autoplay_wifi_key); + final String defaultType = context.getString(R.string.autoplay_wifi_key); + final String always = context.getString(R.string.autoplay_always_key); final String never = context.getString(R.string.autoplay_never_key); final String type = getAutoplayType(context, defaultType); - if (type.equals(wifi)) { - return AUTOPLAY_TYPE_WIFI; + if (type.equals(always)) { + return AUTOPLAY_TYPE_ALWAYS; } else if (type.equals(never)) { return AUTOPLAY_TYPE_NEVER; } else { - return AUTOPLAY_TYPE_ALWAYS; + return AUTOPLAY_TYPE_WIFI; } } diff --git a/app/src/main/res/values/settings_keys.xml b/app/src/main/res/values/settings_keys.xml index ed540ef41..404397450 100644 --- a/app/src/main/res/values/settings_keys.xml +++ b/app/src/main/res/values/settings_keys.xml @@ -65,7 +65,7 @@ autoplay_key - @string/autoplay_always_key + @string/autoplay_wifi_key autoplay_always_key autoplay_wifi_key autoplay_never_key