Optimization of track addition
Created by: Gontran-Molotov
This PR is a small optimization for the addition of tracks:
In Stream.initializeMediaForType()
:
- remove call to
MediaController.isMultiTrackSupportedByType()
as it is also done inMediaController.addTrack()
- fix: remove unused second argument passed to
MediaController.addTrack()
The MediaController.addTrack()
is also slightly refactored to:
- return early if no track passed or track type is not suppored
- use a direct reference to the track list to which passed track should be added.