Bug 1457249 - Assert that there is an animation value set by animations when we skip calculation for newly animation value. r?kats draft
authorHiroyuki Ikezoe <hikezoe@mozilla.com>
Sat, 28 Apr 2018 18:08:15 +0900
changeset 789341 13b43c5214128b84935b6f605c8015f6bac97c62
parent 788735 63a0e2f626febb98d87d2543955ab99a653654ff
child 789342 2f0bfa00a8eb04c05ec8669231d3ac80cd68c522
push id108255
push userhikezoe@mozilla.com
push dateSat, 28 Apr 2018 09:12:02 +0000
reviewerskats
bugs1457249
milestone61.0a1
Bug 1457249 - Assert that there is an animation value set by animations when we skip calculation for newly animation value. r?kats MozReview-Commit-ID: F85nAmKIGCA
gfx/layers/composite/AsyncCompositionManager.cpp
--- a/gfx/layers/composite/AsyncCompositionManager.cpp
+++ b/gfx/layers/composite/AsyncCompositionManager.cpp
@@ -679,21 +679,25 @@ SampleAnimations(Layer* aLayer,
           }
           case AnimationHelper::SampleResult::Skipped:
             // We don't need to update animation values for this layer since
             // the values haven't changed.
 #ifdef DEBUG
             // Sanity check that the animation value is surely unchanged.
             switch (animations[0].property()) {
               case eCSSProperty_opacity:
+                MOZ_ASSERT(
+                  layer->AsHostLayer()->GetShadowOpacitySetByAnimation());
                 MOZ_ASSERT(FuzzyEqualsMultiplicative(
                   layer->AsHostLayer()->GetShadowOpacity(),
                   *(aStorage->GetAnimationOpacity(layer->GetCompositorAnimationsId()))));
                 break;
               case eCSSProperty_transform: {
+                MOZ_ASSERT(
+                  layer->AsHostLayer()->GetShadowTransformSetByAnimation());
                 AnimatedValue* transform =
                   aStorage->GetAnimatedValue(layer->GetCompositorAnimationsId());
                 MOZ_ASSERT(
                   transform->mTransform.mTransformInDevSpace.FuzzyEqualsMultiplicative(
                     (layer->AsHostLayer()->GetShadowBaseTransform())));
                 break;
               }
               default: