Changeset 91999 in webkit


Ignore:
Timestamp:
Jul 29, 2011 10:23:39 AM (13 years ago)
Author:
commit-queue@webkit.org
Message:

Avoid calling animation timer updates while the page is loading
https://bugs.webkit.org/show_bug.cgi?id=64851

Patch by Zeng Huiqing <huiqing.zeng@intel.com> on 2011-07-29
Reviewed by Simon Fraser.

There is no need to update the animation timer for a RenderObject that has not yet been inserted into the render tree, or that doesn't have animations. Our tests show that this improves page loading by up to 3x on pages with a large number of transitionable objects.

  • page/animation/AnimationController.cpp:

(WebCore::AnimationController::updateAnimations):

Location:
trunk/Source/WebCore
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • trunk/Source/WebCore/ChangeLog

    r91998 r91999  
     12011-07-29  Zeng Huiqing  <huiqing.zeng@intel.com>
     2
     3        Avoid calling animation timer updates while the page is loading
     4        https://bugs.webkit.org/show_bug.cgi?id=64851
     5
     6        Reviewed by Simon Fraser.
     7
     8        There is no need to update the animation timer for a RenderObject that has not yet been inserted into the render tree, or that doesn't have animations. Our tests show that this improves page loading by up to 3x on pages with a large number of transitionable objects.
     9
     10        * page/animation/AnimationController.cpp:
     11        (WebCore::AnimationController::updateAnimations):
     12
    1132011-07-29  Anders Carlsson  <andersca@apple.com>
    214
  • trunk/Source/WebCore/page/animation/AnimationController.cpp

    r86981 r91999  
    501501    RefPtr<RenderStyle> blendedStyle = rendererAnimations->animate(renderer, oldStyle, newStyle);
    502502
    503     m_data->updateAnimationTimer();
     503    if (renderer->parent() || newStyle->animations() || (oldStyle && oldStyle->animations()))
     504        m_data->updateAnimationTimer();
    504505
    505506    if (blendedStyle != newStyle) {
Note: See TracChangeset for help on using the changeset viewer.