Bug 1645668 - part1 : reset audible state when aborting current load. r=bryce

When aborting the current load, media element is undoubtedly inaudible. Therefore, we should reset its audible state in order to keep the audible state correct. That can help us show the sound indicator on the tab bar correctly.

Differential Revision: https://phabricator.services.mozilla.com/D81631
This commit is contained in:
alwu
2020-06-30 16:50:35 +00:00
parent c4b54130dd
commit c36b82d85c

View File

@@ -2245,6 +2245,7 @@ void HTMLMediaElement::AbortExistingLoads() {
mWaitingForKey = NOT_WAITING_FOR_KEY;
mSourcePointer = nullptr;
mIsBlessed = false;
SetAudibleState(false);
mTags = nullptr;
mAudioTrackSilenceStartedTime = 0.0;