Fixed to send events only for player playing the actual content.

This commit is contained in:
Olgun Kaya 2021-10-11 19:45:46 +03:00
parent fee3654af5
commit 08952f8525

View File

@ -800,7 +800,7 @@ class ReactExoplayerView extends FrameLayout implements
} }
private void videoLoaded() { private void videoLoaded() {
if (loadVideoStarted) { if (!player.isPlayingAd() && loadVideoStarted) {
loadVideoStarted = false; loadVideoStarted = false;
setSelectedAudioTrack(audioTrackType, audioTrackValue); setSelectedAudioTrack(audioTrackType, audioTrackValue);
setSelectedVideoTrack(videoTrackType, videoTrackValue); setSelectedVideoTrack(videoTrackType, videoTrackValue);