mirror of
https://gitlab.winehq.org/wine/wine-gecko.git
synced 2024-09-13 09:24:08 -07:00
Backed out changeset 9b33c91c851d
This commit is contained in:
parent
54dfd7a69d
commit
52d94b57d2
@ -1084,6 +1084,9 @@ void nsOggDecodeStateMachine::StartPlayback()
|
||||
// Null out mPauseStartTime
|
||||
mPauseStartTime = TimeStamp();
|
||||
}
|
||||
mPlayStartTime = TimeStamp::Now();
|
||||
mPauseDuration = 0;
|
||||
|
||||
}
|
||||
|
||||
void nsOggDecodeStateMachine::StopPlayback()
|
||||
@ -1104,6 +1107,9 @@ void nsOggDecodeStateMachine::PausePlayback()
|
||||
mAudioStream->Pause();
|
||||
mPlaying = PR_FALSE;
|
||||
mPauseStartTime = TimeStamp::Now();
|
||||
if (mAudioStream->GetPosition() < 0) {
|
||||
mLastFrame = mDecodedFrames.ResetTimes(mCallbackPeriod);
|
||||
}
|
||||
}
|
||||
|
||||
void nsOggDecodeStateMachine::ResumePlayback()
|
||||
@ -1122,6 +1128,8 @@ void nsOggDecodeStateMachine::ResumePlayback()
|
||||
// Null out mPauseStartTime
|
||||
mPauseStartTime = TimeStamp();
|
||||
}
|
||||
mPlayStartTime = TimeStamp::Now();
|
||||
mPauseDuration = 0;
|
||||
}
|
||||
|
||||
void nsOggDecodeStateMachine::UpdatePlaybackPosition(float aTime)
|
||||
@ -1501,9 +1509,6 @@ nsresult nsOggDecodeStateMachine::Run()
|
||||
QueueDecodedFrames();
|
||||
while (mDecodedFrames.IsEmpty() && !mDecodingCompleted &&
|
||||
!mBufferExhausted) {
|
||||
if (mPlaying) {
|
||||
PausePlayback();
|
||||
}
|
||||
mon.Wait(PR_MillisecondsToInterval(PRInt64(mCallbackPeriod*500)));
|
||||
if (mState != DECODER_STATE_DECODING)
|
||||
break;
|
||||
|
Loading…
Reference in New Issue
Block a user