mirror of
https://github.com/RGBCube/serenity
synced 2025-07-26 07:17:35 +00:00
LibWeb: Rename confusing parameter in AnimationPlaybackEvent
This commit is contained in:
parent
8c80d0ee02
commit
2e29b0d700
2 changed files with 9 additions and 9 deletions
|
@ -11,19 +11,19 @@ namespace Web::Animations {
|
||||||
|
|
||||||
JS_DEFINE_ALLOCATOR(AnimationPlaybackEvent);
|
JS_DEFINE_ALLOCATOR(AnimationPlaybackEvent);
|
||||||
|
|
||||||
JS::NonnullGCPtr<AnimationPlaybackEvent> AnimationPlaybackEvent::create(JS::Realm& realm, FlyString const& event_name, AnimationPlaybackEventInit const& event_init)
|
JS::NonnullGCPtr<AnimationPlaybackEvent> AnimationPlaybackEvent::create(JS::Realm& realm, FlyString const& type, AnimationPlaybackEventInit const& event_init)
|
||||||
{
|
{
|
||||||
return realm.heap().allocate<AnimationPlaybackEvent>(realm, realm, event_name, event_init);
|
return realm.heap().allocate<AnimationPlaybackEvent>(realm, realm, type, event_init);
|
||||||
}
|
}
|
||||||
|
|
||||||
// https://www.w3.org/TR/web-animations-1/#dom-animationplaybackevent-animationplaybackevent
|
// https://www.w3.org/TR/web-animations-1/#dom-animationplaybackevent-animationplaybackevent
|
||||||
WebIDL::ExceptionOr<JS::NonnullGCPtr<AnimationPlaybackEvent>> AnimationPlaybackEvent::construct_impl(JS::Realm& realm, FlyString const& event_name, AnimationPlaybackEventInit const& event_init)
|
WebIDL::ExceptionOr<JS::NonnullGCPtr<AnimationPlaybackEvent>> AnimationPlaybackEvent::construct_impl(JS::Realm& realm, FlyString const& type, AnimationPlaybackEventInit const& event_init)
|
||||||
{
|
{
|
||||||
return create(realm, event_name, event_init);
|
return create(realm, type, event_init);
|
||||||
}
|
}
|
||||||
|
|
||||||
AnimationPlaybackEvent::AnimationPlaybackEvent(JS::Realm& realm, FlyString const& event_name, AnimationPlaybackEventInit const& event_init)
|
AnimationPlaybackEvent::AnimationPlaybackEvent(JS::Realm& realm, FlyString const& type, AnimationPlaybackEventInit const& event_init)
|
||||||
: DOM::Event(realm, event_name, event_init)
|
: DOM::Event(realm, type, event_init)
|
||||||
, m_current_time(event_init.current_time)
|
, m_current_time(event_init.current_time)
|
||||||
, m_timeline_time(event_init.timeline_time)
|
, m_timeline_time(event_init.timeline_time)
|
||||||
{
|
{
|
||||||
|
|
|
@ -23,8 +23,8 @@ class AnimationPlaybackEvent : public DOM::Event {
|
||||||
JS_DECLARE_ALLOCATOR(AnimationPlaybackEvent);
|
JS_DECLARE_ALLOCATOR(AnimationPlaybackEvent);
|
||||||
|
|
||||||
public:
|
public:
|
||||||
[[nodiscard]] static JS::NonnullGCPtr<AnimationPlaybackEvent> create(JS::Realm&, FlyString const& event_name, AnimationPlaybackEventInit const& event_init = {});
|
[[nodiscard]] static JS::NonnullGCPtr<AnimationPlaybackEvent> create(JS::Realm&, FlyString const& type, AnimationPlaybackEventInit const& event_init = {});
|
||||||
static WebIDL::ExceptionOr<JS::NonnullGCPtr<AnimationPlaybackEvent>> construct_impl(JS::Realm&, FlyString const& event_name, AnimationPlaybackEventInit const& event_init);
|
static WebIDL::ExceptionOr<JS::NonnullGCPtr<AnimationPlaybackEvent>> construct_impl(JS::Realm&, FlyString const& type, AnimationPlaybackEventInit const& event_init);
|
||||||
|
|
||||||
virtual ~AnimationPlaybackEvent() override = default;
|
virtual ~AnimationPlaybackEvent() override = default;
|
||||||
|
|
||||||
|
@ -35,7 +35,7 @@ public:
|
||||||
void set_timeline_time(Optional<double> timeline_time) { m_timeline_time = timeline_time; }
|
void set_timeline_time(Optional<double> timeline_time) { m_timeline_time = timeline_time; }
|
||||||
|
|
||||||
private:
|
private:
|
||||||
AnimationPlaybackEvent(JS::Realm&, FlyString const& event_name, AnimationPlaybackEventInit const& event_init);
|
AnimationPlaybackEvent(JS::Realm&, FlyString const& type, AnimationPlaybackEventInit const& event_init);
|
||||||
|
|
||||||
virtual void initialize(JS::Realm&) override;
|
virtual void initialize(JS::Realm&) override;
|
||||||
|
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue