mirror of
https://github.com/TeamNewPipe/NewPipe.git
synced 2025-10-05 02:39:29 +02:00
Move PlayerType into its own class and add documentation
Also replace some `isPlayerOpen` with direct `playerType == null` checks.
This commit is contained in:
parent
4443c908cb
commit
8187a3bc04
11 changed files with 58 additions and 41 deletions
|
@ -60,7 +60,7 @@ import org.schabi.newpipe.extractor.playlist.PlaylistInfo;
|
|||
import org.schabi.newpipe.extractor.stream.StreamInfo;
|
||||
import org.schabi.newpipe.ktx.ExceptionUtils;
|
||||
import org.schabi.newpipe.local.dialog.PlaylistDialog;
|
||||
import org.schabi.newpipe.player.PlayerService;
|
||||
import org.schabi.newpipe.player.PlayerType;
|
||||
import org.schabi.newpipe.player.helper.PlayerHelper;
|
||||
import org.schabi.newpipe.player.helper.PlayerHolder;
|
||||
import org.schabi.newpipe.player.playqueue.ChannelPlayQueue;
|
||||
|
@ -630,8 +630,8 @@ public class RouterActivity extends AppCompatActivity {
|
|||
}
|
||||
|
||||
// ...the player is not running or in normal Video-mode/type
|
||||
final PlayerService.PlayerType playerType = PlayerHolder.getInstance().getType();
|
||||
return playerType == null || playerType == PlayerService.PlayerType.MAIN;
|
||||
final PlayerType playerType = PlayerHolder.getInstance().getType();
|
||||
return playerType == null || playerType == PlayerType.MAIN;
|
||||
}
|
||||
|
||||
private void openAddToPlaylistDialog() {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue