зеркало из https://github.com/mozilla/gecko-dev.git
Bug 1378586
P4 Clamp setInterval() based on nesting value instead of always. r=farre
This commit is contained in:
Родитель
8547461342
Коммит
90ef714043
|
@ -316,8 +316,7 @@ TimeoutManager::CalculateDelay(Timeout* aTimeout) const {
|
||||||
MOZ_DIAGNOSTIC_ASSERT(aTimeout);
|
MOZ_DIAGNOSTIC_ASSERT(aTimeout);
|
||||||
TimeDuration result = aTimeout->mInterval;
|
TimeDuration result = aTimeout->mInterval;
|
||||||
|
|
||||||
if (aTimeout->mIsInterval ||
|
if (aTimeout->mNestingLevel >= DOM_CLAMP_TIMEOUT_NESTING_LEVEL) {
|
||||||
aTimeout->mNestingLevel >= DOM_CLAMP_TIMEOUT_NESTING_LEVEL) {
|
|
||||||
result = TimeDuration::Max(
|
result = TimeDuration::Max(
|
||||||
result, TimeDuration::FromMilliseconds(gMinClampTimeoutValue));
|
result, TimeDuration::FromMilliseconds(gMinClampTimeoutValue));
|
||||||
}
|
}
|
||||||
|
|
Загрузка…
Ссылка в новой задаче