| OLD | NEW | 
|     1 /* |     1 /* | 
|     2  * Copyright (c) 2013, Google Inc. All rights reserved. |     2  * Copyright (c) 2013, Google Inc. All rights reserved. | 
|     3  * |     3  * | 
|     4  * Redistribution and use in source and binary forms, with or without |     4  * Redistribution and use in source and binary forms, with or without | 
|     5  * modification, are permitted provided that the following conditions are |     5  * modification, are permitted provided that the following conditions are | 
|     6  * met: |     6  * met: | 
|     7  * |     7  * | 
|     8  *     * Redistributions of source code must retain the above copyright |     8  *     * Redistributions of source code must retain the above copyright | 
|     9  * notice, this list of conditions and the following disclaimer. |     9  * notice, this list of conditions and the following disclaimer. | 
|    10  *     * Redistributions in binary form must reproduce the above |    10  *     * Redistributions in binary form must reproduce the above | 
| (...skipping 61 matching lines...) Expand 10 before | Expand all | Expand 10 after  Loading... | 
|    72     RefPtr<TimingFunction> m_cubicCustomTimingFunction; |    72     RefPtr<TimingFunction> m_cubicCustomTimingFunction; | 
|    73     RefPtr<TimingFunction> m_stepTimingFunction; |    73     RefPtr<TimingFunction> m_stepTimingFunction; | 
|    74  |    74  | 
|    75     Timing m_timing; |    75     Timing m_timing; | 
|    76     CompositorAnimationsImpl::CompositorTiming m_compositorTiming; |    76     CompositorAnimationsImpl::CompositorTiming m_compositorTiming; | 
|    77     OwnPtr<AnimatableValueKeyframeVector> m_keyframeVector2; |    77     OwnPtr<AnimatableValueKeyframeVector> m_keyframeVector2; | 
|    78     Persistent<AnimatableValueKeyframeEffectModel> m_keyframeAnimationEffect2; |    78     Persistent<AnimatableValueKeyframeEffectModel> m_keyframeAnimationEffect2; | 
|    79     OwnPtr<AnimatableValueKeyframeVector> m_keyframeVector5; |    79     OwnPtr<AnimatableValueKeyframeVector> m_keyframeVector5; | 
|    80     Persistent<AnimatableValueKeyframeEffectModel> m_keyframeAnimationEffect5; |    80     Persistent<AnimatableValueKeyframeEffectModel> m_keyframeAnimationEffect5; | 
|    81  |    81  | 
|    82     RefPtrWillBePersistent<Document> m_document; |    82     Persistent<Document> m_document; | 
|    83     RefPtrWillBePersistent<Element> m_element; |    83     Persistent<Element> m_element; | 
|    84     Persistent<AnimationTimeline> m_timeline; |    84     Persistent<AnimationTimeline> m_timeline; | 
|    85     OwnPtr<DummyPageHolder> m_pageHolder; |    85     OwnPtr<DummyPageHolder> m_pageHolder; | 
|    86     WebCompositorSupportMock m_mockCompositor; |    86     WebCompositorSupportMock m_mockCompositor; | 
|    87  |    87  | 
|    88     virtual void SetUp() |    88     virtual void SetUp() | 
|    89     { |    89     { | 
|    90         AnimationCompositorAnimationsTestBase::SetUp(); |    90         AnimationCompositorAnimationsTestBase::SetUp(); | 
|    91         setCompositorForTesting(m_mockCompositor); |    91         setCompositorForTesting(m_mockCompositor); | 
|    92  |    92  | 
|    93         m_linearTimingFunction = LinearTimingFunction::shared(); |    93         m_linearTimingFunction = LinearTimingFunction::shared(); | 
| (...skipping 1076 matching lines...) Expand 10 before | Expand all | Expand 10 after  Loading... | 
|  1170  |  1170  | 
|  1171     // Go! |  1171     // Go! | 
|  1172     Vector<OwnPtr<WebCompositorAnimation>> result; |  1172     Vector<OwnPtr<WebCompositorAnimation>> result; | 
|  1173     getAnimationOnCompositor(m_timing, *effect, result); |  1173     getAnimationOnCompositor(m_timing, *effect, result); | 
|  1174     EXPECT_EQ(1U, result.size()); |  1174     EXPECT_EQ(1U, result.size()); | 
|  1175     result[0].clear(); |  1175     result[0].clear(); | 
|  1176 } |  1176 } | 
|  1177  |  1177  | 
|  1178 TEST_F(AnimationCompositorAnimationsTest, CancelIncompatibleCompositorAnimations
      ) |  1178 TEST_F(AnimationCompositorAnimationsTest, CancelIncompatibleCompositorAnimations
      ) | 
|  1179 { |  1179 { | 
|  1180     RefPtrWillBePersistent<Element> element = m_document->createElement("shared"
      , ASSERT_NO_EXCEPTION); |  1180     Persistent<Element> element = m_document->createElement("shared", ASSERT_NO_
      EXCEPTION); | 
|  1181  |  1181  | 
|  1182     LayoutObjectProxy* layoutObject = LayoutObjectProxy::create(element.get()); |  1182     LayoutObjectProxy* layoutObject = LayoutObjectProxy::create(element.get()); | 
|  1183     element->setLayoutObject(layoutObject); |  1183     element->setLayoutObject(layoutObject); | 
|  1184  |  1184  | 
|  1185     AnimatableValueKeyframeVector keyFrames; |  1185     AnimatableValueKeyframeVector keyFrames; | 
|  1186     keyFrames.append(createDefaultKeyframe(CSSPropertyOpacity, EffectModel::Comp
      ositeReplace, 0.0).get()); |  1186     keyFrames.append(createDefaultKeyframe(CSSPropertyOpacity, EffectModel::Comp
      ositeReplace, 0.0).get()); | 
|  1187     keyFrames.append(createDefaultKeyframe(CSSPropertyOpacity, EffectModel::Comp
      ositeReplace, 1.0).get()); |  1187     keyFrames.append(createDefaultKeyframe(CSSPropertyOpacity, EffectModel::Comp
      ositeReplace, 1.0).get()); | 
|  1188     EffectModel* animationEffect1 = AnimatableValueKeyframeEffectModel::create(k
      eyFrames); |  1188     EffectModel* animationEffect1 = AnimatableValueKeyframeEffectModel::create(k
      eyFrames); | 
|  1189     EffectModel* animationEffect2 = AnimatableValueKeyframeEffectModel::create(k
      eyFrames); |  1189     EffectModel* animationEffect2 = AnimatableValueKeyframeEffectModel::create(k
      eyFrames); | 
|  1190  |  1190  | 
| (...skipping 28 matching lines...) Expand all  Loading... | 
|  1219     simulateFrame(1.); |  1219     simulateFrame(1.); | 
|  1220  |  1220  | 
|  1221     element->setLayoutObject(nullptr); |  1221     element->setLayoutObject(nullptr); | 
|  1222     LayoutObjectProxy::dispose(layoutObject); |  1222     LayoutObjectProxy::dispose(layoutObject); | 
|  1223  |  1223  | 
|  1224     Heap::collectAllGarbage(); |  1224     Heap::collectAllGarbage(); | 
|  1225     EXPECT_TRUE(element->elementAnimations()->animations().isEmpty()); |  1225     EXPECT_TRUE(element->elementAnimations()->animations().isEmpty()); | 
|  1226 } |  1226 } | 
|  1227  |  1227  | 
|  1228 } // namespace blink |  1228 } // namespace blink | 
| OLD | NEW |