Changeset 233141 in webkit
- Timestamp:
- Jun 25, 2018 3:00:42 AM (6 years ago)
- Location:
- trunk
- Files:
-
- 7 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/LayoutTests/ChangeLog
r233138 r233141 1 2018-06-25 Antoine Quint <graouts@apple.com> 2 3 [Web Animations] Make imported/mozilla/css-animations/test_animation-pausing.html pass reliably 4 https://bugs.webkit.org/show_bug.cgi?id=183826 5 <rdar://problem/40997412> 6 7 Reviewed by Dean Jackson. 8 9 This test now passes reliably. 10 11 * TestExpectations: 12 1 13 2018-06-25 Zan Dobersek <zdobersek@igalia.com> 2 14 -
trunk/LayoutTests/TestExpectations
r233099 r233141 1931 1931 webkit.org/b/181888 imported/w3c/web-platform-tests/web-animations/timing-model/animation-effects/current-iteration.html [ Pass Failure ] 1932 1932 1933 webkit.org/b/183826 imported/mozilla/css-animations/test_animation-pausing.html [ Pass Failure Timeout ]1934 1933 webkit.org/b/183834 imported/mozilla/css-animations/test_animation-starttime.html [ Pass Failure Timeout ] 1935 1934 webkit.org/b/183836 imported/mozilla/css-animations/test_animations-dynamic-changes.html [ Pass Failure Timeout ] -
trunk/LayoutTests/imported/mozilla/ChangeLog
r233140 r233141 1 2018-06-25 Antoine Quint <graouts@apple.com> 2 3 [Web Animations] Make imported/mozilla/css-animations/test_animation-pausing.html pass reliably 4 https://bugs.webkit.org/show_bug.cgi?id=183826 5 <rdar://problem/40997412> 6 7 Reviewed by Dean Jackson. 8 9 Mark progressions in the Mozilla CSS Animations tests. 10 11 * css-animations/test_animation-pausing-expected.txt: 12 1 13 2018-06-25 Antoine Quint <graouts@apple.com> 2 14 -
trunk/LayoutTests/imported/mozilla/css-animations/test_animation-pausing-expected.txt
r233140 r233141 1 1 2 2 PASS play() overrides animation-play-state 3 FAIL pause() overrides animation-play-state assert_equals: Paused value of margin-left is zero expected 0 but got 0.03600386157631874 3 PASS pause() overrides animation-play-state 4 4 PASS play() is overridden by later setting "animation-play-state: paused" 5 5 PASS play() flushes pending changes to animation-play-state first -
trunk/Source/WebCore/ChangeLog
r233140 r233141 1 2018-06-25 Antoine Quint <graouts@apple.com> 2 3 [Web Animations] Make imported/mozilla/css-animations/test_animation-pausing.html pass reliably 4 https://bugs.webkit.org/show_bug.cgi?id=183826 5 <rdar://problem/40997412> 6 7 Reviewed by Dean Jackson. 8 9 The CSS Animations Level 2 specification defines that calling pause() on a CSSAnimation object is "sticky" 10 until a call to play() is made, meaning that any changes to the running state via the CSS animation-play-state 11 property is overridden by the stickiness of the pause() call. In this patch we add an m_stickyPaused flag which 12 is set in API calls to pause() and play(). While this flag is true, changes to the animation-play-state property 13 to the "running" value are ignored. 14 15 * animation/CSSAnimation.cpp: 16 (WebCore::CSSAnimation::syncPropertiesWithBackingAnimation): 17 (WebCore::CSSAnimation::bindingsPlay): 18 (WebCore::CSSAnimation::bindingsPause): 19 * animation/CSSAnimation.h: 20 1 21 2018-06-25 Antoine Quint <graouts@apple.com> 2 22 -
trunk/Source/WebCore/animation/CSSAnimation.cpp
r233051 r233141 92 92 93 93 // Synchronize the play state 94 if (animation.playState() == AnimationPlayState::Playing && playState() == WebAnimation::PlayState::Paused) 95 play(); 96 else if (animation.playState() == AnimationPlayState::Paused && playState() == WebAnimation::PlayState::Running) 94 if (animation.playState() == AnimationPlayState::Playing && playState() == WebAnimation::PlayState::Paused) { 95 if (!m_stickyPaused) 96 play(); 97 } else if (animation.playState() == AnimationPlayState::Paused && playState() == WebAnimation::PlayState::Running) 97 98 pause(); 98 99 … … 154 155 { 155 156 flushPendingStyleChanges(); 157 m_stickyPaused = false; 156 158 return DeclarativeAnimation::bindingsPlay(); 157 159 } … … 160 162 { 161 163 flushPendingStyleChanges(); 164 m_stickyPaused = true; 162 165 return DeclarativeAnimation::bindingsPause(); 163 166 } -
trunk/Source/WebCore/animation/CSSAnimation.h
r233051 r233141 65 65 String m_animationName; 66 66 std::unique_ptr<RenderStyle> m_unanimatedStyle; 67 bool m_stickyPaused { false }; 67 68 }; 68 69
Note: See TracChangeset
for help on using the changeset viewer.