OLD | NEW |
1 /* | 1 /* |
2 * Copyright (C) 2013 Google Inc. All rights reserved. | 2 * Copyright (C) 2013 Google Inc. All rights reserved. |
3 * | 3 * |
4 * Redistribution and use in source and binary forms, with or without | 4 * Redistribution and use in source and binary forms, with or without |
5 * modification, are permitted provided that the following conditions are | 5 * modification, are permitted provided that the following conditions are |
6 * met: | 6 * met: |
7 * | 7 * |
8 * * Redistributions of source code must retain the above copyright | 8 * * Redistributions of source code must retain the above copyright |
9 * notice, this list of conditions and the following disclaimer. | 9 * notice, this list of conditions and the following disclaimer. |
10 * * Redistributions in binary form must reproduce the above | 10 * * Redistributions in binary form must reproduce the above |
(...skipping 507 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
518 #if ENABLE(ASSERT) | 518 #if ENABLE(ASSERT) |
519 // In debug builds we verify that it would have been safe to avoid populatin
g and testing listedProperties if the style recalc is due to animation. | 519 // In debug builds we verify that it would have been safe to avoid populatin
g and testing listedProperties if the style recalc is due to animation. |
520 const bool animationStyleRecalc = false; | 520 const bool animationStyleRecalc = false; |
521 #else | 521 #else |
522 // In release builds we avoid the cost of checking for new and interrupted t
ransitions if the style recalc is due to animation. | 522 // In release builds we avoid the cost of checking for new and interrupted t
ransitions if the style recalc is due to animation. |
523 const bool animationStyleRecalc = elementAnimations && elementAnimations->is
AnimationStyleChange(); | 523 const bool animationStyleRecalc = elementAnimations && elementAnimations->is
AnimationStyleChange(); |
524 #endif | 524 #endif |
525 | 525 |
526 BitArray<numCSSProperties> listedProperties; | 526 BitArray<numCSSProperties> listedProperties; |
527 bool anyTransitionHadTransitionAll = false; | 527 bool anyTransitionHadTransitionAll = false; |
528 const LayoutObject* renderer = animatingElement->renderer(); | 528 const LayoutObject* renderer = animatingElement->layoutObject(); |
529 if (!animationStyleRecalc && style.display() != NONE && renderer && renderer
->style() && transitionData) { | 529 if (!animationStyleRecalc && style.display() != NONE && renderer && renderer
->style() && transitionData) { |
530 const LayoutStyle& oldStyle = *renderer->style(); | 530 const LayoutStyle& oldStyle = *renderer->style(); |
531 | 531 |
532 for (size_t i = 0; i < transitionData->propertyList().size(); ++i) { | 532 for (size_t i = 0; i < transitionData->propertyList().size(); ++i) { |
533 const CSSTransitionData::TransitionProperty& transitionProperty = tr
ansitionData->propertyList()[i]; | 533 const CSSTransitionData::TransitionProperty& transitionProperty = tr
ansitionData->propertyList()[i]; |
534 CSSTransitionData::TransitionPropertyType mode = transitionProperty.
propertyType; | 534 CSSTransitionData::TransitionPropertyType mode = transitionProperty.
propertyType; |
535 CSSPropertyID property = transitionProperty.propertyId; | 535 CSSPropertyID property = transitionProperty.propertyId; |
536 if (mode == CSSTransitionData::TransitionNone || mode == CSSTransiti
onData::TransitionUnknown) | 536 if (mode == CSSTransitionData::TransitionNone || mode == CSSTransiti
onData::TransitionUnknown) |
537 continue; | 537 continue; |
538 | 538 |
(...skipping 266 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
805 visitor->trace(m_activeInterpolationsForAnimations); | 805 visitor->trace(m_activeInterpolationsForAnimations); |
806 visitor->trace(m_activeInterpolationsForTransitions); | 806 visitor->trace(m_activeInterpolationsForTransitions); |
807 visitor->trace(m_newAnimations); | 807 visitor->trace(m_newAnimations); |
808 visitor->trace(m_suppressedAnimationPlayers); | 808 visitor->trace(m_suppressedAnimationPlayers); |
809 visitor->trace(m_animationsWithUpdates); | 809 visitor->trace(m_animationsWithUpdates); |
810 visitor->trace(m_animationsWithStyleUpdates); | 810 visitor->trace(m_animationsWithStyleUpdates); |
811 #endif | 811 #endif |
812 } | 812 } |
813 | 813 |
814 } // namespace blink | 814 } // namespace blink |
OLD | NEW |