Add support for transitionrun events

These events are triggered as soon as a transition is added to the list
of running transitions. This will allow better test coverage while
reworking the transitions and animations processing model.
This commit is contained in:
Martin Robinson 2020-04-23 17:06:24 +02:00
parent 0540c4a284
commit d386d6d1f1
11 changed files with 105 additions and 93 deletions

View file

@ -647,6 +647,7 @@ fn invoke(
atom!("animationiteration") => Some(atom!("webkitAnimationIteration")),
atom!("animationstart") => Some(atom!("webkitAnimationStart")),
atom!("transitionend") => Some(atom!("webkitTransitionEnd")),
atom!("transitionrun") => Some(atom!("webkitTransitionRun")),
_ => None,
} {
let original_type = event.type_();

View file

@ -498,6 +498,7 @@ macro_rules! global_event_handlers(
event_handler!(toggle, GetOntoggle, SetOntoggle);
event_handler!(transitioncancel, GetOntransitioncancel, SetOntransitioncancel);
event_handler!(transitionend, GetOntransitionend, SetOntransitionend);
event_handler!(transitionrun, GetOntransitionrun, SetOntransitionrun);
event_handler!(volumechange, GetOnvolumechange, SetOnvolumechange);
event_handler!(waiting, GetOnwaiting, SetOnwaiting);
)

View file

@ -92,6 +92,7 @@ interface mixin GlobalEventHandlers {
// https://drafts.csswg.org/css-transitions/#interface-globaleventhandlers-idl
partial interface mixin GlobalEventHandlers {
attribute EventHandler ontransitionrun;
attribute EventHandler ontransitionend;
attribute EventHandler ontransitioncancel;
};