Animation Worklet - WorkletAnimation::cancel does not clean up the compositor animation |
||
Issue descriptionCancelling a worklet animation does not clean up the compositor animation correctly. Correct behavior in this case should remove the compositor animation and causing the main and impl state to reflect as if the animation no longer exist.
,
Apr 18 2018
The following revision refers to this bug: https://chromium.googlesource.com/chromium/src.git/+/f1827a376f57d0e18a513670bda0ddc8d684c57b commit f1827a376f57d0e18a513670bda0ddc8d684c57b Author: Majid Valipour <majidvp@chromium.org> Date: Wed Apr 18 23:24:19 2018 [animation-worklet] Fix worklet animation cancel Add logic to properly cancel and remove compositor animation when a worklet animation is cancelled. The logic mimics what we normally do for other animations: (1) Cancel the effect on compositor (=> removes effect from compositor animation) (2) Detach element from compositor animation (3) Detach compositor animation from its timeline (4) null the compositor animation Previously, we were not doing above which left the animation alive on compositor. Note that while this correctly cleans up the compositor animation but the last produced value from animation on compositor remains. Normally this gets cleaned up in the next commit but there is another bug where cancelling animation does not cause a follow up commit. The test in this case forces a commit by manually dirtying style on the target element. Bug: 829926 Change-Id: I566b4a0ee5e2a2d06603c385daf489108ce3d0e4 Reviewed-on: https://chromium-review.googlesource.com/999032 Reviewed-by: Stephen McGruer <smcgruer@chromium.org> Reviewed-by: Majid Valipour <majidvp@chromium.org> Commit-Queue: Majid Valipour <majidvp@chromium.org> Cr-Commit-Position: refs/heads/master@{#551878} [add] https://crrev.com/f1827a376f57d0e18a513670bda0ddc8d684c57b/third_party/WebKit/LayoutTests/virtual/threaded/fast/animationworklet/worklet-animation-cancel-expected.html [add] https://crrev.com/f1827a376f57d0e18a513670bda0ddc8d684c57b/third_party/WebKit/LayoutTests/virtual/threaded/fast/animationworklet/worklet-animation-cancel.html [modify] https://crrev.com/f1827a376f57d0e18a513670bda0ddc8d684c57b/third_party/blink/renderer/core/animation/animation.cc [modify] https://crrev.com/f1827a376f57d0e18a513670bda0ddc8d684c57b/third_party/blink/renderer/core/animation/compositor_animations.cc [modify] https://crrev.com/f1827a376f57d0e18a513670bda0ddc8d684c57b/third_party/blink/renderer/core/animation/compositor_animations.h [modify] https://crrev.com/f1827a376f57d0e18a513670bda0ddc8d684c57b/third_party/blink/renderer/core/animation/keyframe_effect.cc [modify] https://crrev.com/f1827a376f57d0e18a513670bda0ddc8d684c57b/third_party/blink/renderer/core/animation/keyframe_effect.h [modify] https://crrev.com/f1827a376f57d0e18a513670bda0ddc8d684c57b/third_party/blink/renderer/core/animation/worklet_animation_controller.cc [modify] https://crrev.com/f1827a376f57d0e18a513670bda0ddc8d684c57b/third_party/blink/renderer/modules/animationworklet/worklet_animation.cc [modify] https://crrev.com/f1827a376f57d0e18a513670bda0ddc8d684c57b/third_party/blink/renderer/modules/animationworklet/worklet_animation.h
,
Jun 13 2018
|
||
►
Sign in to add a comment |
||
Comment 1 by majidvp@chromium.org
, Apr 17 2018