WebKit Bugzilla
Attachment 343034 Details for
Bug 183821
: [Web Animations] Make imported/mozilla/css-transitions/test_animation-cancel.html pass reliably
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Requests
|
Help
|
New Account
|
Log In
Remember
[x]
|
Forgot Password
Login:
[x]
[patch]
Patch
bug-183821-20180619113647.patch (text/plain), 7.86 KB, created by
Antoine Quint
on 2018-06-19 02:36:48 PDT
(
hide
)
Description:
Patch
Filename:
MIME Type:
Creator:
Antoine Quint
Created:
2018-06-19 02:36:48 PDT
Size:
7.86 KB
patch
obsolete
>Subversion Revision: 232953 >diff --git a/Source/WebCore/ChangeLog b/Source/WebCore/ChangeLog >index 8ee076cb267862d4a44e16ad6bf6b77272ef33d5..cb1e9d1466f0ba6c84032524d6b94b440909bc9f 100644 >--- a/Source/WebCore/ChangeLog >+++ b/Source/WebCore/ChangeLog >@@ -1,3 +1,21 @@ >+2018-06-19 Antoine Quint <graouts@apple.com> >+ >+ [Web Animations] Make imported/mozilla/css-transitions/test_animation-cancel.html pass reliably >+ https://bugs.webkit.org/show_bug.cgi?id=183821 >+ <rdar://problem/40997034> >+ >+ Reviewed by NOBODY (OOPS!). >+ >+ If an element gets a "display: none" style RenderTreeUpdater::tearDownRenderers() will be called with a RendererUpdateCancelingAnimations >+ teardown type on all of its children. We need to ensure all declarative animations, and only those since regular Web Animations should be >+ kept active regardless of their target's style, are canceled in this situation. >+ >+ * animation/AnimationTimeline.cpp: >+ (WebCore::AnimationTimeline::cancelDeclarativeAnimationsForElement): >+ * animation/AnimationTimeline.h: >+ * rendering/updating/RenderTreeUpdater.cpp: >+ (WebCore::RenderTreeUpdater::tearDownRenderers): >+ > 2018-06-18 Chris Dumez <cdumez@apple.com> > > Better pack ResourceRequest >diff --git a/Source/WebCore/animation/AnimationTimeline.cpp b/Source/WebCore/animation/AnimationTimeline.cpp >index 0c0e10db44df6adfa82515865d9635bbe7f48537..52fc1a00892bfa141762e6eab506d03aebdd0ac6 100644 >--- a/Source/WebCore/animation/AnimationTimeline.cpp >+++ b/Source/WebCore/animation/AnimationTimeline.cpp >@@ -168,6 +168,14 @@ void AnimationTimeline::removeAnimationsForElement(Element& element) > } > } > >+void AnimationTimeline::cancelDeclarativeAnimationsForElement(Element& element) >+{ >+ for (auto& cssTransition : m_elementToCSSTransitionsMap.get(&element)) >+ cssTransition->cancel(); >+ for (auto& cssAnimation : m_elementToCSSAnimationsMap.get(&element)) >+ cssAnimation->cancel(); >+} >+ > void AnimationTimeline::updateCSSAnimationsForElement(Element& element, const RenderStyle* currentStyle, const RenderStyle& afterChangeStyle) > { > // In case this element is newly getting a "display: none" we need to cancel all of its animations and disregard new ones. >diff --git a/Source/WebCore/animation/AnimationTimeline.h b/Source/WebCore/animation/AnimationTimeline.h >index fe9a7c6d40f8f30fc93ad5d7e5024b51d56982de..139272ca941bcc0eb83e37599a404de5281f212b 100644 >--- a/Source/WebCore/animation/AnimationTimeline.h >+++ b/Source/WebCore/animation/AnimationTimeline.h >@@ -60,6 +60,7 @@ public: > const ListHashSet<RefPtr<WebAnimation>>& animations() const { return m_animations; } > Vector<RefPtr<WebAnimation>> animationsForElement(Element&) const; > void removeAnimationsForElement(Element&); >+ void cancelDeclarativeAnimationsForElement(Element&); > void animationWasAddedToElement(WebAnimation&, Element&); > void animationWasRemovedFromElement(WebAnimation&, Element&); > >diff --git a/Source/WebCore/rendering/updating/RenderTreeUpdater.cpp b/Source/WebCore/rendering/updating/RenderTreeUpdater.cpp >index fa2a4c680b098a810961564f206793f083341236..e43d22efa622faa53e1a6291f0e41ac098a2c3d1 100644 >--- a/Source/WebCore/rendering/updating/RenderTreeUpdater.cpp >+++ b/Source/WebCore/rendering/updating/RenderTreeUpdater.cpp >@@ -554,8 +554,12 @@ void RenderTreeUpdater::tearDownRenderers(Element& root, TeardownType teardownTy > > if (teardownType == TeardownType::Full || teardownType == TeardownType::RendererUpdateCancelingAnimations) { > if (RuntimeEnabledFeatures::sharedFeatures().webAnimationsCSSIntegrationEnabled()) { >- if (timeline && document.renderTreeBeingDestroyed()) >- timeline->removeAnimationsForElement(element); >+ if (timeline) { >+ if (document.renderTreeBeingDestroyed()) >+ timeline->removeAnimationsForElement(element); >+ else if (teardownType == TeardownType::RendererUpdateCancelingAnimations) >+ timeline->cancelDeclarativeAnimationsForElement(element); >+ } > } else > animationController.cancelAnimations(element); > } >diff --git a/LayoutTests/ChangeLog b/LayoutTests/ChangeLog >index 4c1565e2304e1b69ff131d4c55b726ecd9266a51..49562fb4e6cae944c1576fb513d3ce7349239a33 100644 >--- a/LayoutTests/ChangeLog >+++ b/LayoutTests/ChangeLog >@@ -1,3 +1,15 @@ >+2018-06-19 Antoine Quint <graouts@apple.com> >+ >+ [Web Animations] Make imported/mozilla/css-transitions/test_animation-cancel.html pass reliably >+ https://bugs.webkit.org/show_bug.cgi?id=183821 >+ <rdar://problem/40997034> >+ >+ Reviewed by NOBODY (OOPS!). >+ >+ This test now passes reliably. >+ >+ * TestExpectations: >+ > 2018-06-18 Antoine Quint <graouts@apple.com> > > [Web Animations] Implement "Starting of transitions" section from CSS Transitions >diff --git a/LayoutTests/imported/mozilla/ChangeLog b/LayoutTests/imported/mozilla/ChangeLog >index e860efde5c2d27364081d1d259b2e7bc00e4e1ce..e3a1981aefb256ee601c3ee18481db66e8231675 100644 >--- a/LayoutTests/imported/mozilla/ChangeLog >+++ b/LayoutTests/imported/mozilla/ChangeLog >@@ -1,3 +1,15 @@ >+2018-06-19 Antoine Quint <graouts@apple.com> >+ >+ [Web Animations] Make imported/mozilla/css-transitions/test_animation-cancel.html pass reliably >+ https://bugs.webkit.org/show_bug.cgi?id=183821 >+ <rdar://problem/40997034> >+ >+ Reviewed by NOBODY (OOPS!). >+ >+ Mark a progression in the Mozilla CSS Transitions tests. >+ >+ * css-transitions/test_animation-cancel-expected.txt: >+ > 2018-06-18 Antoine Quint <graouts@apple.com> > > [Web Animations] Implement "Starting of transitions" section from CSS Transitions >diff --git a/LayoutTests/TestExpectations b/LayoutTests/TestExpectations >index 8962af5c96ab6a64107fccb3e079a37a5139ff6f..1fe002d0846071a9cd4dbefb636c4ef21436a599 100644 >--- a/LayoutTests/TestExpectations >+++ b/LayoutTests/TestExpectations >@@ -1928,7 +1928,6 @@ webkit.org/b/181888 imported/w3c/web-platform-tests/web-animations/timing-model/ > > webkit.org/b/183818 imported/mozilla/css-animations/test_pseudoElement-get-animations.html [ Pass Failure Timeout ] > webkit.org/b/184011 imported/mozilla/css-animations/test_animation-cancel.html [ Pass Failure ] >-webkit.org/b/183821 imported/mozilla/css-transitions/test_animation-cancel.html [ Pass Failure Timeout ] > webkit.org/b/183826 imported/mozilla/css-animations/test_animation-pausing.html [ Pass Failure Timeout ] > webkit.org/b/183828 imported/mozilla/css-animations/test_animation-playstate.html [ Pass Failure Timeout ] > webkit.org/b/183830 imported/mozilla/css-animations/test_animation-ready.html [ Pass Failure Timeout ] >diff --git a/LayoutTests/imported/mozilla/css-transitions/test_animation-cancel-expected.txt b/LayoutTests/imported/mozilla/css-transitions/test_animation-cancel-expected.txt >index 003935e1da4542b170a8cb58c8dbdb8ee676d891..ae6b3030641b3343eb6ef87e98ca47eb4a266d69 100644 >--- a/LayoutTests/imported/mozilla/css-transitions/test_animation-cancel-expected.txt >+++ b/LayoutTests/imported/mozilla/css-transitions/test_animation-cancel-expected.txt >@@ -4,7 +4,7 @@ PASS After canceling a transition, it can still be re-used > PASS After cancelling a finished transition, it can still be re-used > PASS After cancelling a transition, updating transition properties doesn't make it live again > PASS Setting display:none on an element cancels its transitions >-FAIL Setting display:none cancels transitions on a child element assert_equals: expected "idle" but got "running" >+PASS Setting display:none cancels transitions on a child element > PASS Removing a property from transition-property cancels transitions on that property > PASS Setting zero combined duration > PASS Changing style to another interpolable value cancels the original transition
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Flags:
dino
:
review+
ews-watchlist
:
commit-queue-
Actions:
View
|
Formatted Diff
|
Diff
Attachments on
bug 183821
: 343034 |
343048