Minified code

This commit is contained in:
litetex 2021-12-26 23:57:54 +01:00 committed by GitHub
parent 989bcbf895
commit b67bf16d4f
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 6 additions and 8 deletions

View File

@ -168,14 +168,12 @@ public final class NavigationHelper {
public static void playOnBackgroundPlayer(final Context context,
final PlayQueue queue,
final boolean resumePlayback) {
final int toastText;
if (PlayerHolder.getInstance().getType() == MainPlayer.PlayerType.AUDIO) {
toastText = R.string.background_player_already_playing_toast;
} else {
toastText = R.string.background_player_playing_toast;
}
Toast.makeText(context, toastText, Toast.LENGTH_SHORT)
Toast.makeText(
context,
PlayerHolder.getInstance().getType() == PlayerType.AUDIO
? R.string.background_player_playing_toast
: R.string.background_player_playing_toast,
Toast.LENGTH_SHORT)
.show();
final Intent intent = getPlayerIntent(context, MainPlayer.class, queue, resumePlayback);