mirror of
https://github.com/samsonjs/media.git
synced 2026-04-23 14:15:48 +00:00
Fix NPE in track selection view
------------- Created by MOE: https://github.com/google/moe MOE_MIGRATED_REVID=129336905
This commit is contained in:
parent
c2c41558e5
commit
52d9539878
1 changed files with 4 additions and 3 deletions
|
|
@ -87,8 +87,9 @@ import java.util.Locale;
|
|||
trackGroupsAdaptive = new boolean[trackGroups.length];
|
||||
for (int i = 0; i < trackGroups.length; i++) {
|
||||
trackGroupsAdaptive[i] = adaptiveVideoTrackSelectionFactory != null
|
||||
&& (trackInfo.getAdaptiveSupport(rendererIndex, i, false)
|
||||
!= RendererCapabilities.ADAPTIVE_NOT_SUPPORTED);
|
||||
&& trackInfo.getAdaptiveSupport(rendererIndex, i, false)
|
||||
!= RendererCapabilities.ADAPTIVE_NOT_SUPPORTED
|
||||
&& trackGroups.get(i).length > 1;
|
||||
}
|
||||
isDisabled = selector.getRendererDisabled(rendererIndex);
|
||||
override = selector.hasSelectionOverride(rendererIndex, trackGroups)
|
||||
|
|
@ -131,7 +132,7 @@ import java.util.Locale;
|
|||
trackViews = new CheckedTextView[trackGroups.length][];
|
||||
for (int groupIndex = 0; groupIndex < trackGroups.length; groupIndex++) {
|
||||
TrackGroup group = trackGroups.get(groupIndex);
|
||||
boolean groupIsAdaptive = group.length > 1 && trackGroupsAdaptive[groupIndex];
|
||||
boolean groupIsAdaptive = trackGroupsAdaptive[groupIndex];
|
||||
haveAdaptiveTracks |= groupIsAdaptive;
|
||||
trackViews[groupIndex] = new CheckedTextView[group.length];
|
||||
for (int trackIndex = 0; trackIndex < group.length; trackIndex++) {
|
||||
|
|
|
|||
Loading…
Reference in a new issue