From 051e18b26fdb0f3489ff3ac5414b82feb719d26c Mon Sep 17 00:00:00 2001 From: olly Date: Thu, 9 Sep 2021 10:13:23 +0100 Subject: [PATCH] Fix STATE_IDLE Javadoc Since playlist support was added, it's possible for the player to "have media" and be in STATE_IDLE. The STATE_IDLE documentation therefore became incorrect. Issue: #8946 #exofixit #minor-release PiperOrigin-RevId: 395653716 --- .../main/java/com/google/android/exoplayer2/Player.java | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/library/common/src/main/java/com/google/android/exoplayer2/Player.java b/library/common/src/main/java/com/google/android/exoplayer2/Player.java index dfa80d40b4..26a0ba46d3 100644 --- a/library/common/src/main/java/com/google/android/exoplayer2/Player.java +++ b/library/common/src/main/java/com/google/android/exoplayer2/Player.java @@ -988,11 +988,12 @@ public interface Player { @Retention(RetentionPolicy.SOURCE) @IntDef({STATE_IDLE, STATE_BUFFERING, STATE_READY, STATE_ENDED}) @interface State {} - /** The player does not have any media to play. */ + /** The player is idle, and must be {@link #prepare() prepared} before it will play the media. */ int STATE_IDLE = 1; /** - * The player is not able to immediately play from its current position. This state typically - * occurs when more data needs to be loaded. + * The player is not able to immediately play the media, but is doing work toward being able to do + * so. This state typically occurs when the player needs to buffer more data before playback can + * start. */ int STATE_BUFFERING = 2; /**