зеркало из https://github.com/mozilla/gecko-dev.git
Bug 1294629 - Simplify the code of ReaderSuspendedChanged(). r=kaku
SetDormant() checks IsShutdown() and |mState == DECODER_STATE_DORMANT|. So ReaderSuspendedChanged() can just call SetDormant(mIsReaderSuspended) to do the work. MozReview-Commit-ID: J7Dzsm8IhIS --HG-- extra : rebase_source : c8a0bc31071bfbe084c2a5f47821c0dc3cfd0860
This commit is contained in:
Родитель
2a5c775eea
Коммит
cef7b4cae0
|
@ -1400,15 +1400,7 @@ void MediaDecoderStateMachine::ReaderSuspendedChanged()
|
|||
{
|
||||
MOZ_ASSERT(OnTaskQueue());
|
||||
DECODER_LOG("ReaderSuspendedChanged: %d", mIsReaderSuspended.Ref());
|
||||
|
||||
if (IsShutdown()) {
|
||||
return;
|
||||
}
|
||||
if (mIsReaderSuspended && mState != DECODER_STATE_DORMANT) {
|
||||
SetDormant(true);
|
||||
} else if (!mIsReaderSuspended && mState == DECODER_STATE_DORMANT) {
|
||||
SetDormant(false);
|
||||
}
|
||||
SetDormant(mIsReaderSuspended);
|
||||
}
|
||||
|
||||
void
|
||||
|
|
Загрузка…
Ссылка в новой задаче