Map PLAYER_STATE_LOADING to STATE_BUFFERING

#minor-release
Issue: androidx/media#245
PiperOrigin-RevId: 510456793
This commit is contained in:
bachinger 2023-02-17 17:55:44 +00:00 committed by Andrew Lewis
parent 8aa1638fe4
commit a231ff4fa9

View file

@ -1235,6 +1235,7 @@ public final class CastPlayer extends BasePlayer {
int receiverAppStatus = remoteMediaClient.getPlayerState();
switch (receiverAppStatus) {
case MediaStatus.PLAYER_STATE_BUFFERING:
case MediaStatus.PLAYER_STATE_LOADING:
return STATE_BUFFERING;
case MediaStatus.PLAYER_STATE_PLAYING:
case MediaStatus.PLAYER_STATE_PAUSED:
@ -1297,6 +1298,7 @@ public final class CastPlayer extends BasePlayer {
return false;
}
@SuppressWarnings("VisibleForTests")
private static int getCastRepeatMode(@RepeatMode int repeatMode) {
switch (repeatMode) {
case REPEAT_MODE_ONE: