| OLD | NEW |
| 1 /* | 1 /* |
| 2 * Copyright (C) 1999 Lars Knoll (knoll@kde.org) | 2 * Copyright (C) 1999 Lars Knoll (knoll@kde.org) |
| 3 * (C) 2004-2005 Allan Sandfeld Jensen (kde@carewolf.com) | 3 * (C) 2004-2005 Allan Sandfeld Jensen (kde@carewolf.com) |
| 4 * Copyright (C) 2006, 2007 Nicholas Shanks (webkit@nickshanks.com) | 4 * Copyright (C) 2006, 2007 Nicholas Shanks (webkit@nickshanks.com) |
| 5 * Copyright (C) 2005, 2006, 2007, 2008, 2009, 2010, 2011, 2012, 2013 Apple Inc. | 5 * Copyright (C) 2005, 2006, 2007, 2008, 2009, 2010, 2011, 2012, 2013 Apple Inc. |
| 6 * All rights reserved. | 6 * All rights reserved. |
| 7 * Copyright (C) 2007 Alexey Proskuryakov <ap@webkit.org> | 7 * Copyright (C) 2007 Alexey Proskuryakov <ap@webkit.org> |
| 8 * Copyright (C) 2007, 2008 Eric Seidel <eric@webkit.org> | 8 * Copyright (C) 2007, 2008 Eric Seidel <eric@webkit.org> |
| 9 * Copyright (C) 2008, 2009 Torch Mobile Inc. All rights reserved. | 9 * Copyright (C) 2008, 2009 Torch Mobile Inc. All rights reserved. |
| 10 * (http://www.torchmobile.com/) | 10 * (http://www.torchmobile.com/) |
| (...skipping 594 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 605 // presence of custom property animations that don't affect pre-animated | 605 // presence of custom property animations that don't affect pre-animated |
| 606 // computed values. | 606 // computed values. |
| 607 return nullptr; | 607 return nullptr; |
| 608 } | 608 } |
| 609 | 609 |
| 610 return elementAnimations->baseComputedStyle(); | 610 return elementAnimations->baseComputedStyle(); |
| 611 } | 611 } |
| 612 | 612 |
| 613 static void updateBaseComputedStyle(StyleResolverState& state, | 613 static void updateBaseComputedStyle(StyleResolverState& state, |
| 614 Element* animatingElement) { | 614 Element* animatingElement) { |
| 615 if (!animatingElement || state.isAnimatingCustomProperties()) | 615 if (!animatingElement) |
| 616 return; | 616 return; |
| 617 | 617 |
| 618 ElementAnimations* elementAnimations = animatingElement->elementAnimations(); | 618 ElementAnimations* elementAnimations = animatingElement->elementAnimations(); |
| 619 if (elementAnimations) | 619 if (elementAnimations) { |
| 620 elementAnimations->updateBaseComputedStyle(state.style()); | 620 if (state.isAnimatingCustomProperties()) { |
| 621 elementAnimations->clearBaseComputedStyle(); |
| 622 } else { |
| 623 elementAnimations->updateBaseComputedStyle(state.style()); |
| 624 } |
| 625 } |
| 621 } | 626 } |
| 622 | 627 |
| 623 PassRefPtr<ComputedStyle> StyleResolver::styleForElement( | 628 PassRefPtr<ComputedStyle> StyleResolver::styleForElement( |
| 624 Element* element, | 629 Element* element, |
| 625 const ComputedStyle* defaultParent, | 630 const ComputedStyle* defaultParent, |
| 626 const ComputedStyle* defaultLayoutParent, | 631 const ComputedStyle* defaultLayoutParent, |
| 627 StyleSharingBehavior sharingBehavior, | 632 StyleSharingBehavior sharingBehavior, |
| 628 RuleMatchingBehavior matchingBehavior) { | 633 RuleMatchingBehavior matchingBehavior) { |
| 629 DCHECK(document().frame()); | 634 DCHECK(document().frame()); |
| 630 DCHECK(document().settings()); | 635 DCHECK(document().settings()); |
| (...skipping 1332 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1963 | 1968 |
| 1964 DEFINE_TRACE(StyleResolver) { | 1969 DEFINE_TRACE(StyleResolver) { |
| 1965 visitor->trace(m_matchedPropertiesCache); | 1970 visitor->trace(m_matchedPropertiesCache); |
| 1966 visitor->trace(m_selectorFilter); | 1971 visitor->trace(m_selectorFilter); |
| 1967 visitor->trace(m_styleSharingLists); | 1972 visitor->trace(m_styleSharingLists); |
| 1968 visitor->trace(m_document); | 1973 visitor->trace(m_document); |
| 1969 visitor->trace(m_tracker); | 1974 visitor->trace(m_tracker); |
| 1970 } | 1975 } |
| 1971 | 1976 |
| 1972 } // namespace blink | 1977 } // namespace blink |
| OLD | NEW |