Bug 1207734 - Part 9. Update LayerAnimationInfo list. draft
authorcku <cku@mozilla.com>
Wed, 06 Dec 2017 23:42:26 +0800
changeset 708796 071dd0a3ea3939f3d355c6a841a77bdd58507aed
parent 708795 c87717f189adcd3d87d928e0d11b2d1f9d3e4f21
child 708797 072441e227b8f4b90bbd98954f591fdfbcf0dacb
push id92453
push userbmo:cku@mozilla.com
push dateThu, 07 Dec 2017 06:47:04 +0000
bugs1207734
milestone59.0a1
Bug 1207734 - Part 9. Update LayerAnimationInfo list. MozReview-Commit-ID: GVcjfGQIJ6O
layout/style/LayerAnimationInfo.cpp
layout/style/LayerAnimationInfo.h
--- a/layout/style/LayerAnimationInfo.cpp
+++ b/layout/style/LayerAnimationInfo.cpp
@@ -9,16 +9,25 @@
 #include "nsCSSProps.h" // For nsCSSProps::PropHasFlags
 
 namespace mozilla {
 
 /* static */ const LayerAnimationInfo::Record LayerAnimationInfo::sRecords[] =
   { { eCSSProperty_transform,
       DisplayItemType::TYPE_TRANSFORM,
       nsChangeHint_UpdateTransformLayer },
+    { eCSSProperty_rotate,
+      DisplayItemType::TYPE_TRANSFORM,
+      nsChangeHint_UpdateTransformLayer },
+    { eCSSProperty_translate,
+      DisplayItemType::TYPE_TRANSFORM,
+      nsChangeHint_UpdateTransformLayer },
+    { eCSSProperty_scale,
+      DisplayItemType::TYPE_TRANSFORM,
+      nsChangeHint_UpdateTransformLayer },
     { eCSSProperty_opacity,
       DisplayItemType::TYPE_OPACITY,
       nsChangeHint_UpdateOpacityLayer } };
 
 #ifdef DEBUG
 /* static */ void
 LayerAnimationInfo::Initialize()
 {
--- a/layout/style/LayerAnimationInfo.h
+++ b/layout/style/LayerAnimationInfo.h
@@ -20,15 +20,15 @@ struct LayerAnimationInfo {
   // For CSS properties that may be animated on a separate layer, represents
   // a record of the corresponding layer type and change hint.
   struct Record {
     nsCSSPropertyID mProperty;
     DisplayItemType mLayerType;
     nsChangeHint mChangeHint;
   };
 
-  static const size_t kRecords = 2;
+  static const size_t kRecords = 5;
   static const Record sRecords[kRecords];
 };
 
 } // namespace mozilla
 
 #endif /* !defined(mozilla_LayerAnimationInfo_h) */