2
0
mirror of https://github.com/TeamNewPipe/NewPipe synced 2025-08-22 10:09:39 +00:00

Use regions

This commit is contained in:
litetex 2025-07-26 15:43:36 +02:00 committed by Stypox
parent 71fcc5ebce
commit 859555e129
No known key found for this signature in database
GPG Key ID: 4BDF1B40A49FDD23

View File

@ -89,9 +89,7 @@ public final class PlayerHelper {
private PlayerHelper() { private PlayerHelper() {
} }
//////////////////////////////////////////////////////////////////////////// // region Exposed helpers
// Exposed helpers
////////////////////////////////////////////////////////////////////////////
@NonNull @NonNull
public static String getTimeString(final int milliSeconds) { public static String getTimeString(final int milliSeconds) {
@ -219,9 +217,8 @@ public final class PlayerHelper {
? null : getAutoQueuedSinglePlayQueue(autoQueueItems.get(0)); ? null : getAutoQueuedSinglePlayQueue(autoQueueItems.get(0));
} }
//////////////////////////////////////////////////////////////////////////// // endregion
// Settings Resolution // region Resolution
////////////////////////////////////////////////////////////////////////////
public static boolean isResumeAfterAudioFocusGain(@NonNull final Context context) { public static boolean isResumeAfterAudioFocusGain(@NonNull final Context context) {
return getPreferences(context) return getPreferences(context)
@ -405,9 +402,8 @@ public final class PlayerHelper {
return Integer.parseInt(preferredIntervalBytes) * 1024; return Integer.parseInt(preferredIntervalBytes) * 1024;
} }
//////////////////////////////////////////////////////////////////////////// // endregion
// Private helpers // region Private helpers
////////////////////////////////////////////////////////////////////////////
@NonNull @NonNull
private static SharedPreferences getPreferences(@NonNull final Context context) { private static SharedPreferences getPreferences(@NonNull final Context context) {
@ -427,9 +423,8 @@ public final class PlayerHelper {
} }
//////////////////////////////////////////////////////////////////////////// // endregion
// Utils used by player // region Utils used by player
////////////////////////////////////////////////////////////////////////////
@RepeatMode @RepeatMode
public static int nextRepeatMode(@RepeatMode final int repeatMode) { public static int nextRepeatMode(@RepeatMode final int repeatMode) {
@ -503,4 +498,6 @@ public final class PlayerHelper {
player.getContext().getString(R.string.seek_duration_key), player.getContext().getString(R.string.seek_duration_key),
player.getContext().getString(R.string.seek_duration_default_value)))); player.getContext().getString(R.string.seek_duration_default_value))));
} }
// endregion
} }