Skip to content

Commit 49b1649

Browse files
committed
Revert "Merge pull request #7568 from vhouriet/vhouriet_feature_already-playing-in-backgroud"
This reverts commit ee19ea6, reversing changes made to 6b490ee.
1 parent 9f50391 commit 49b1649

2 files changed

Lines changed: 4 additions & 9 deletions

File tree

app/src/main/java/org/schabi/newpipe/util/NavigationHelper.java

Lines changed: 4 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -168,14 +168,10 @@ public static void playOnPopupPlayer(final Context context,
168168
public static void playOnBackgroundPlayer(final Context context,
169169
final PlayQueue queue,
170170
final boolean resumePlayback) {
171-
Toast.makeText(
172-
context,
173-
PlayerHolder.getInstance().getType() == PlayerType.AUDIO
174-
? R.string.background_player_already_playing_toast
175-
: R.string.background_player_playing_toast,
176-
Toast.LENGTH_SHORT)
177-
.show();
178-
171+
if (PlayerHolder.getInstance().getType() != MainPlayer.PlayerType.AUDIO) {
172+
Toast.makeText(context, R.string.background_player_playing_toast, Toast.LENGTH_SHORT)
173+
.show();
174+
}
179175
final Intent intent = getPlayerIntent(context, MainPlayer.class, queue, resumePlayback);
180176
intent.putExtra(Player.PLAYER_TYPE, MainPlayer.PlayerType.AUDIO.ordinal());
181177
ContextCompat.startForegroundService(context, intent);

app/src/main/res/values/strings.xml

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -143,7 +143,6 @@
143143
<string name="settings_category_updates_title">Updates</string>
144144
<string name="settings_category_notification_title">Notification</string>
145145
<string name="background_player_playing_toast">Playing in background</string>
146-
<string name="background_player_already_playing_toast">Already playing in background</string>
147146
<string name="popup_playing_toast">Playing in popup mode</string>
148147
<string name="content">Content</string>
149148
<string name="show_age_restricted_content_title">Show age restricted content</string>

0 commit comments

Comments
 (0)