mirror of
https://github.com/samsonjs/media.git
synced 2026-03-25 09:25:53 +00:00
Remove dead code in ProgressiveMediaSource.Builder
These fields cannot be set and the logic to handle them can be removed.
PiperOrigin-RevId: 544646460
(cherry picked from commit 2f113c8b82)
This commit is contained in:
parent
3a66617b9e
commit
aefba8a565
1 changed files with 0 additions and 12 deletions
|
|
@ -62,8 +62,6 @@ public final class ProgressiveMediaSource extends BaseMediaSource
|
|||
private DrmSessionManagerProvider drmSessionManagerProvider;
|
||||
private LoadErrorHandlingPolicy loadErrorHandlingPolicy;
|
||||
private int continueLoadingCheckIntervalBytes;
|
||||
@Nullable private String customCacheKey;
|
||||
@Nullable private Object tag;
|
||||
|
||||
/**
|
||||
* Creates a new factory for {@link ProgressiveMediaSource}s.
|
||||
|
|
@ -207,16 +205,6 @@ public final class ProgressiveMediaSource extends BaseMediaSource
|
|||
@Override
|
||||
public ProgressiveMediaSource createMediaSource(MediaItem mediaItem) {
|
||||
checkNotNull(mediaItem.localConfiguration);
|
||||
boolean needsTag = mediaItem.localConfiguration.tag == null && tag != null;
|
||||
boolean needsCustomCacheKey =
|
||||
mediaItem.localConfiguration.customCacheKey == null && customCacheKey != null;
|
||||
if (needsTag && needsCustomCacheKey) {
|
||||
mediaItem = mediaItem.buildUpon().setTag(tag).setCustomCacheKey(customCacheKey).build();
|
||||
} else if (needsTag) {
|
||||
mediaItem = mediaItem.buildUpon().setTag(tag).build();
|
||||
} else if (needsCustomCacheKey) {
|
||||
mediaItem = mediaItem.buildUpon().setCustomCacheKey(customCacheKey).build();
|
||||
}
|
||||
return new ProgressiveMediaSource(
|
||||
mediaItem,
|
||||
dataSourceFactory,
|
||||
|
|
|
|||
Loading…
Reference in a new issue