Bug 1588138 - reset blessed state when media aborting current load. r=bryce
This patch is used to change the blessed state for media element under `click-to-play` blocking autoplay policy, which only allows play invocation called from user input handler, eg. `onclick`. When media aborts current load, we should regard it as a new media. One example is on Youtube they always reuse same media element but replace its url for different video. Therefore, we should reset media's blessed state so that the media with new url can be blocked again. Differential Revision: https://phabricator.services.mozilla.com/D57192
This commit is contained in:
@@ -2178,6 +2178,7 @@ void HTMLMediaElement::AbortExistingLoads() {
|
||||
mPendingEncryptedInitData.Reset();
|
||||
mWaitingForKey = NOT_WAITING_FOR_KEY;
|
||||
mSourcePointer = nullptr;
|
||||
mIsBlessed = false;
|
||||
|
||||
mTags = nullptr;
|
||||
mAudioTrackSilenceStartedTime = 0.0;
|
||||
|
||||
Reference in New Issue
Block a user