mirror of
https://github.com/mozilla/gecko-dev.git
synced 2024-12-25 17:43:44 +00:00
Bug 1069289 - take |mAudioEndTime| into account when updating playback position at the end of playback. r=kinetik
This commit is contained in:
parent
049052f05d
commit
83dc138454
@ -2478,8 +2478,8 @@ nsresult MediaDecoderStateMachine::RunStateMachine()
|
||||
// will take care of calling MediaDecoder::PlaybackEnded.
|
||||
if (mDecoder->GetState() == MediaDecoder::PLAY_STATE_PLAYING &&
|
||||
!mDecoder->GetDecodedStream()) {
|
||||
int64_t videoTime = HasVideo() ? mVideoFrameEndTime : 0;
|
||||
int64_t clockTime = std::max(mEndTime, videoTime);
|
||||
int64_t clockTime = std::max(mAudioEndTime, mVideoFrameEndTime);
|
||||
clockTime = std::max(int64_t(0), std::max(clockTime, mEndTime));
|
||||
UpdatePlaybackPosition(clockTime);
|
||||
|
||||
{
|
||||
|
Loading…
Reference in New Issue
Block a user