Show audio as enabled when an audio track is present in stream

This commit is contained in:
trav90
2016-10-21 03:57:07 -05:00
committed by roytam1
parent d6335febb4
commit bd103574cf
2 changed files with 27 additions and 0 deletions
+6
View File
@@ -3490,6 +3490,12 @@ void HTMLMediaElement::UpdateReadyStateForData(MediaDecoderOwner::NextFrameStatu
// We are playing a stream that has video and a video frame is now set.
// This means we have all metadata needed to change ready state.
MediaInfo mediaInfo = mMediaInfo;
if (hasAudio) {
mediaInfo.EnableAudio();
}
if (hasVideo) {
mediaInfo.EnableVideo();
}
MetadataLoaded(&mediaInfo, nsAutoPtr<const MetadataTags>(nullptr));
}