fix(android): remove remaining ad view when zapping (#3786)
* perf: ensure we do not provide callback to native if no callback provided from app * chore: rework bufferConfig to make it more generic and reduce ReactExoplayerView code size * chore: improve issue template * fix(android): avoid video view flickering at playback startup * fix(android): ensure adsLoader is well release if unused
This commit is contained in:
parent
8ee4bccc37
commit
324b461527
@ -712,6 +712,11 @@ public class ReactExoplayerView extends FrameLayout implements
|
||||
.setLocalAdInsertionComponents(unusedAdTagUri -> adsLoader, exoPlayerView);
|
||||
DataSpec adTagDataSpec = new DataSpec(adTagUrl);
|
||||
mediaSourceWithAds = new AdsMediaSource(videoSource, adTagDataSpec, ImmutableList.of(srcUri, adTagUrl), mediaSourceFactory, adsLoader, exoPlayerView);
|
||||
} else {
|
||||
if (adTagUrl == null && adsLoader != null) {
|
||||
adsLoader.release();
|
||||
adsLoader = null;
|
||||
}
|
||||
}
|
||||
MediaSource mediaSource;
|
||||
if (mediaSourceList.size() == 0) {
|
||||
|
Loading…
Reference in New Issue
Block a user