Changeset 141314 in webkit


Ignore:
Timestamp:
Jan 30, 2013 2:32:30 PM (11 years ago)
Author:
commit-queue@webkit.org
Message:

Remove unnecessary setAnimating() method
https://bugs.webkit.org/show_bug.cgi?id=107495

Patch by Douglas Stockwell <dstockwell@chromium.org> on 2013-01-30
Reviewed by Dean Jackson.

The corresponding accessor and uses were removed in r39211.

No new tests: no change in behaviour.

  • page/animation/AnimationBase.cpp:

(WebCore::AnimationBase::AnimationBase):

  • page/animation/AnimationBase.h:

(AnimationBase):

  • page/animation/CompositeAnimation.cpp:
  • page/animation/CompositeAnimation.h:
  • page/animation/ImplicitAnimation.cpp:

(WebCore::ImplicitAnimation::animate):

  • page/animation/KeyframeAnimation.cpp:

(WebCore::KeyframeAnimation::animate):

Location:
trunk/Source/WebCore
Files:
7 edited

Legend:

Unmodified
Added
Removed
  • trunk/Source/WebCore/ChangeLog

    r141313 r141314  
     12013-01-30  Douglas Stockwell  <dstockwell@chromium.org>
     2
     3        Remove unnecessary setAnimating() method
     4        https://bugs.webkit.org/show_bug.cgi?id=107495
     5
     6        Reviewed by Dean Jackson.
     7
     8        The corresponding accessor and uses were removed in r39211.
     9
     10        No new tests: no change in behaviour.
     11
     12        * page/animation/AnimationBase.cpp:
     13        (WebCore::AnimationBase::AnimationBase):
     14        * page/animation/AnimationBase.h:
     15        (AnimationBase):
     16        * page/animation/CompositeAnimation.cpp:
     17        * page/animation/CompositeAnimation.h:
     18        * page/animation/ImplicitAnimation.cpp:
     19        (WebCore::ImplicitAnimation::animate):
     20        * page/animation/KeyframeAnimation.cpp:
     21        (WebCore::KeyframeAnimation::animate):
     22
    1232013-01-30  Elliott Sprehn  <esprehn@chromium.org>
    224
  • trunk/Source/WebCore/page/animation/AnimationBase.cpp

    r120639 r141314  
    7171AnimationBase::AnimationBase(const Animation* transition, RenderObject* renderer, CompositeAnimation* compAnim)
    7272    : m_animState(AnimationStateNew)
    73     , m_isAnimating(false)
    7473    , m_isAccelerated(false)
    7574    , m_transformFunctionListValid(false)
  • trunk/Source/WebCore/page/animation/AnimationBase.h

    r115581 r141314  
    130130    bool waitingForStyleAvailable() const { return m_animState == AnimationStateStartWaitStyleAvailable; }
    131131
    132     // "animating" means that something is running that requires a timer to keep firing
    133     // (e.g. a software animation)
    134     void setAnimating(bool inAnimating = true) { m_isAnimating = inAnimating; }
    135132    virtual double timeToNextService();
    136133
     
    225222    AnimState m_animState;
    226223
    227     bool m_isAnimating;       // transition/animation requires continual timer firing
    228224    bool m_isAccelerated;
    229225    bool m_transformFunctionListValid;
  • trunk/Source/WebCore/page/animation/CompositeAnimation.cpp

    r137243 r141314  
    326326}
    327327
    328 // "animating" means that something is running that requires the timer to keep firing
    329 void CompositeAnimation::setAnimating(bool animating)
    330 {
    331     if (!m_transitions.isEmpty()) {
    332         CSSPropertyTransitionsMap::const_iterator transitionsEnd = m_transitions.end();
    333         for (CSSPropertyTransitionsMap::const_iterator it = m_transitions.begin(); it != transitionsEnd; ++it) {
    334             ImplicitAnimation* transition = it->value.get();
    335             transition->setAnimating(animating);
    336         }
    337     }
    338     if (!m_keyframeAnimations.isEmpty()) {
    339         m_keyframeAnimations.checkConsistency();
    340         AnimationNameMap::const_iterator animationsEnd = m_keyframeAnimations.end();
    341         for (AnimationNameMap::const_iterator it = m_keyframeAnimations.begin(); it != animationsEnd; ++it) {
    342             KeyframeAnimation* anim = it->value.get();
    343             anim->setAnimating(animating);
    344         }
    345     }
    346 }
    347 
    348328double CompositeAnimation::timeToNextService() const
    349329{
  • trunk/Source/WebCore/page/animation/CompositeAnimation.h

    r137243 r141314  
    6969    bool hasAnimations() const  { return !m_transitions.isEmpty() || !m_keyframeAnimations.isEmpty(); }
    7070
    71     void setAnimating(bool);
    7271    bool isAnimatingProperty(CSSPropertyID, bool acceleratedOnly, bool isRunningNow) const;
    7372
  • trunk/Source/WebCore/page/animation/ImplicitAnimation.cpp

    r139762 r141314  
    8282    // FIXME: we also need to detect cases where we have to software animate for other reasons,
    8383    // such as a child using inheriting the transform. https://bugs.webkit.org/show_bug.cgi?id=23902
    84     if (needsAnim)
    85         setAnimating();
    86     else {
    87 #if USE(ACCELERATED_COMPOSITING)
     84#if USE(ACCELERATED_COMPOSITING)
     85    if (!needsAnim)
    8886        // If we are running an accelerated animation, set a flag in the style which causes the style
    8987        // to compare as different to any other style. This ensures that changes to the property
     
    9290        animatedStyle->setIsRunningAcceleratedAnimation();
    9391#endif
    94     }
    9592
    9693    // Fire the start timeout if needed
  • trunk/Source/WebCore/page/animation/KeyframeAnimation.cpp

    r120639 r141314  
    188188   
    189189        bool needsAnim = CSSPropertyAnimation::blendProperties(this, *it, animatedStyle.get(), fromStyle, toStyle, progress);
    190         if (needsAnim)
    191             setAnimating();
    192         else {
    193190#if USE(ACCELERATED_COMPOSITING)
     191        if (!needsAnim)
    194192            // If we are running an accelerated animation, set a flag in the style
    195193            // to indicate it. This can be used to make sure we get an updated
     
    197195            animatedStyle->setIsRunningAcceleratedAnimation();
    198196#endif
    199         }
    200197    }
    201198}
Note: See TracChangeset for help on using the changeset viewer.