Commit ce0cf23a by ibaker Committed by bachinger

Migrate callers of ExoPlayer.Builder#build() to buildExoPlayer()

An upcoming change will update build() to return Player.

PiperOrigin-RevId: 399981901
parent d5ef11aa
......@@ -90,7 +90,7 @@ import java.util.ArrayList;
currentItemIndex = C.INDEX_UNSET;
trackSelector = new DefaultTrackSelector(context);
exoPlayer = new ExoPlayer.Builder(context).setTrackSelector(trackSelector).build();
exoPlayer = new ExoPlayer.Builder(context).setTrackSelector(trackSelector).buildExoPlayer();
exoPlayer.addListener(this);
localPlayerView.setPlayer(exoPlayer);
......
......@@ -278,7 +278,7 @@ public class PlayerActivity extends AppCompatActivity
new ExoPlayer.Builder(/* context= */ this, renderersFactory)
.setMediaSourceFactory(mediaSourceFactory)
.setTrackSelector(trackSelector)
.build();
.buildExoPlayer();
player.addListener(new PlayerEventListener());
player.addAnalyticsListener(new EventLogger(trackSelector));
player.setAudioAttributes(AudioAttributes.DEFAULT, /* handleAudioFocus= */ true);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or sign in to comment