[SCM] WebKit Debian packaging branch, debian/experimental, updated. upstream/1.3.3-9427-gc2be6fc

simon.fraser at apple.com simon.fraser at apple.com
Wed Dec 22 13:10:05 UTC 2010


The following commit has been merged in the debian/experimental branch:
commit 92b5fb612cd22bd1b394cef5996620ebfe4cb068
Author: simon.fraser at apple.com <simon.fraser at apple.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Date:   Wed Sep 8 01:10:02 2010 +0000

    2010-09-07  Simon Fraser  <simon.fraser at apple.com>
    
            Reviewed by Chris Marrin.
    
            Transform animations always run in software now
            https://bugs.webkit.org/show_bug.cgi?id=45341
    
            After r66339 we always fell into software animation, because we
            failed to detect transform or opacity properties in the keyframes,
            so would send an empty list of values to the GraphicsLayer.
    
            Fixed by using CSSProperty values, rather than GraphicsLayer
            values, when detecting the presence of properties in the keyframes.
    
            Test: manual-tests/transition-accelerated.html
    
            * rendering/RenderLayerBacking.cpp:
            (WebCore::RenderLayerBacking::startAnimation):
    
    git-svn-id: http://svn.webkit.org/repository/webkit/trunk@66942 268f45cc-cd09-0410-ab3c-d52691b4dbfc

diff --git a/WebCore/ChangeLog b/WebCore/ChangeLog
index c8434d2..1f74a91 100644
--- a/WebCore/ChangeLog
+++ b/WebCore/ChangeLog
@@ -1,3 +1,22 @@
+2010-09-07  Simon Fraser  <simon.fraser at apple.com>
+
+        Reviewed by Chris Marrin.
+
+        Transform animations always run in software now
+        https://bugs.webkit.org/show_bug.cgi?id=45341
+        
+        After r66339 we always fell into software animation, because we
+        failed to detect transform or opacity properties in the keyframes,
+        so would send an empty list of values to the GraphicsLayer.
+        
+        Fixed by using CSSProperty values, rather than GraphicsLayer
+        values, when detecting the presence of properties in the keyframes.
+        
+        Test: manual-tests/transition-accelerated.html
+
+        * rendering/RenderLayerBacking.cpp:
+        (WebCore::RenderLayerBacking::startAnimation):
+
 2010-09-07  Chris Rogers  <crogers at google.com>
 
         Reviewed by Kenneth Russell.
diff --git a/WebCore/manual-tests/transition-accelerated.html b/WebCore/manual-tests/transition-accelerated.html
new file mode 100644
index 0000000..a898c29
--- /dev/null
+++ b/WebCore/manual-tests/transition-accelerated.html
@@ -0,0 +1,46 @@
+<!DOCTYPE html>
+
+<html>
+<head>
+  <style type="text/css" media="screen">
+    .box {
+      position: relative;
+      height: 100px;
+      width: 100px;
+      margin: 10px;
+      background-color: blue;
+    }
+    
+    .slow {
+      -webkit-animation: slow 2s infinite linear alternate;
+    }
+    
+    .fast {
+      -webkit-animation: fast 2s infinite linear alternate;
+    }
+    
+    @-webkit-keyframes slow {
+      from {
+        left: 0px;
+      }
+      to {
+        left: 400px;
+      }
+    }
+
+    @-webkit-keyframes fast {
+      from {
+        -webkit-transform: translateX(0);
+      }
+      to {
+        -webkit-transform: translateX(400px);
+      }
+    }
+  </style>
+</head>
+<body>
+  <p>The lower box should animate more smoothly than the upper one (on Mac).</p>
+  <div class="box slow"></div>
+  <div class="box fast"></div>
+</body>
+</html>
diff --git a/WebCore/rendering/RenderLayerBacking.cpp b/WebCore/rendering/RenderLayerBacking.cpp
index f9090ba..981fa16 100644
--- a/WebCore/rendering/RenderLayerBacking.cpp
+++ b/WebCore/rendering/RenderLayerBacking.cpp
@@ -1127,10 +1127,10 @@ bool RenderLayerBacking::startAnimation(double timeOffset, const Animation* anim
         // get timing function
         const TimingFunction* tf = keyframeStyle->hasAnimations() ? &((*keyframeStyle->animations()).animation(0)->timingFunction()) : 0;
         
-        if (currentKeyframe.containsProperty(AnimatedPropertyWebkitTransform))
+        if (currentKeyframe.containsProperty(CSSPropertyWebkitTransform))
             transformVector.insert(new TransformAnimationValue(key, &(keyframeStyle->transform()), tf));
         
-        if (currentKeyframe.containsProperty(AnimatedPropertyOpacity))
+        if (currentKeyframe.containsProperty(CSSPropertyOpacity))
             opacityVector.insert(new FloatAnimationValue(key, keyframeStyle->opacity(), tf));
     }
 

-- 
WebKit Debian packaging



More information about the Pkg-webkit-commits mailing list