Branch: refs/heads/main
  Home:   https://github.com/WebKit/WebKit
  Commit: 2f89cb3ece5bf30312d87035082caae3ee17cfb5
      
https://github.com/WebKit/WebKit/commit/2f89cb3ece5bf30312d87035082caae3ee17cfb5
  Author: Antoine Quint <grao...@webkit.org>
  Date:   2025-04-24 (Thu, 24 Apr 2025)

  Changed paths:
    M LayoutTests/TestExpectations
    M Source/WebCore/animation/AnimationTimelinesController.cpp

  Log Message:
  -----------
  [scroll-animations] WPT test 
scroll-animations/view-timelines/animation-events.html is a flaky failure
https://bugs.webkit.org/show_bug.cgi?id=284299

Reviewed by Anne van Kesteren.

The Web Animations spec says that pending animation events should be enqueued 
per document, and we
made the choice years ago to host the event queue on the `DocumentTimeline` 
created for each document.

When document timelines were the only timeline types, running the "update 
animation and send events"
procedure [0] would only ever run if the document timeline needed an update. 
When we started supporting
multiple types of timelines, this meant we could run that procedure when a 
scroll or view timeline
needed an update but the document timeline did not.

As such, we change the step where we process events in the "update animation 
and send events" procedure
to not only look for a document timeline among the timelines needing an update, 
but always looking at
the document timeline created for the document.

A better fix would be to stop enqueuing events on `DocumentTimeline` and 
instead on
`AnimationTimelinesController` but the given the scope of that potential change 
and how simple
this fix is, it seems like a better solution for the time being.

[0] https://drafts.csswg.org/web-animations-1/#update-animations-and-send-events

* LayoutTests/TestExpectations:
* Source/WebCore/animation/AnimationTimelinesController.cpp:
(WebCore::AnimationTimelinesController::updateAnimationsAndSendEvents):

Canonical link: https://commits.webkit.org/294068@main



To unsubscribe from these emails, change your notification settings at 
https://github.com/WebKit/WebKit/settings/notifications
_______________________________________________
webkit-changes mailing list
webkit-changes@lists.webkit.org
https://lists.webkit.org/mailman/listinfo/webkit-changes

Reply via email to