File tree Expand file tree Collapse file tree 3 files changed +3
-10
lines changed
Libraries/LibWeb/Animations Expand file tree Collapse file tree 3 files changed +3
-10
lines changed Original file line number Diff line number Diff line change @@ -17,9 +17,9 @@ class AnimationTimeline : public Bindings::PlatformObject {
1717 GC_DECLARE_ALLOCATOR (AnimationTimeline);
1818
1919public:
20- Optional< double > current_time_for_bindings () const
20+ NullableCSSNumberish current_time_for_bindings () const
2121 {
22- return current_time (). map ([]( auto const & current_time) { return current_time. as_milliseconds (); } );
22+ return NullableCSSNumberish::from_optional_css_numberish_time ( current_time () );
2323 }
2424 Optional<TimeValue> current_time () const ;
2525
Original file line number Diff line number Diff line change 33// https://drafts.csswg.org/web-animations-2/#the-animationtimeline-interface
44[Exposed=Window]
55interface AnimationTimeline {
6- [ImplementedAs=current_time_for_bindings] readonly attribute double ? currentTime;
6+ [ImplementedAs=current_time_for_bindings] readonly attribute CSSNumberish ? currentTime;
77 [ImplementedAs=duration_for_bindings] readonly attribute CSSNumberish? duration;
88 [FIXME] Animation play (optional AnimationEffect? effect = null);
99};
Original file line number Diff line number Diff line change @@ -77,13 +77,6 @@ struct TimeValue {
7777 return type == other.type && value == other.value ;
7878 }
7979
80- // FIXME: This method is temporary as we migrate all CSS timing to use TimeValue.
81- double as_milliseconds () const
82- {
83- VERIFY (type == Type::Milliseconds);
84- return value;
85- }
86-
8780 CSS::CSSNumberish as_css_numberish () const
8881 {
8982 switch (type) {
You can’t perform that action at this time.
0 commit comments