double KeyframeAnimation::timeToNextService() { double t = AnimationBase::timeToNextService(); #if USE(ACCELERATED_COMPOSITING) if (t != 0 || preActive()) return t; // A return value of 0 means we need service. But if we only have accelerated animations we // only need service at the end of the transition HashSet<int>::const_iterator endProperties = m_keyframes.endProperties(); bool acceleratedPropertiesOnly = true; for (HashSet<int>::const_iterator it = m_keyframes.beginProperties(); it != endProperties; ++it) { if (!animationOfPropertyIsAccelerated(*it) || isFallbackAnimating()) { acceleratedPropertiesOnly = false; break; } } if (acceleratedPropertiesOnly) { bool isLooping; getTimeToNextEvent(t, isLooping); } #endif return t; }
double ImplicitAnimation::timeToNextService() { double t = AnimationBase::timeToNextService(); #if USE(ACCELERATED_COMPOSITING) if (t != 0 || preActive()) return t; // A return value of 0 means we need service. But if this is an accelerated animation we // only need service at the end of the transition. if (animationOfPropertyIsAccelerated(m_animatingProperty) && isAccelerated()) { bool isLooping; getTimeToNextEvent(t, isLooping); } #endif return t; }