mirror of
https://github.com/servo/servo.git
synced 2025-08-05 13:40:08 +01:00
implements nsStyleCounterData type properties animatable
This commit is contained in:
parent
a155a6341d
commit
6316b7aeb8
2 changed files with 13 additions and 2 deletions
|
@ -4511,6 +4511,17 @@ clip-path
|
||||||
bindings::Gecko_CopyCounter${counter_property}sFrom(&mut self.gecko, &other.gecko)
|
bindings::Gecko_CopyCounter${counter_property}sFrom(&mut self.gecko, &other.gecko)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
pub fn clone_counter_${counter_property.lower()}(&self) -> longhands::counter_increment::computed_value::T {
|
||||||
|
use values::CustomIdent;
|
||||||
|
use gecko_string_cache::Atom;
|
||||||
|
|
||||||
|
longhands::counter_increment::computed_value::T(
|
||||||
|
self.gecko.m${counter_property}s.iter().map(|ref gecko_counter| {
|
||||||
|
(CustomIdent(Atom::from(gecko_counter.mCounter.to_string())), gecko_counter.mValue)
|
||||||
|
}).collect()
|
||||||
|
)
|
||||||
|
}
|
||||||
% endfor
|
% endfor
|
||||||
</%self:impl_trait>
|
</%self:impl_trait>
|
||||||
|
|
||||||
|
|
|
@ -233,7 +233,7 @@
|
||||||
}
|
}
|
||||||
</%helpers:longhand>
|
</%helpers:longhand>
|
||||||
|
|
||||||
<%helpers:longhand name="counter-increment" animation_value_type="none"
|
<%helpers:longhand name="counter-increment" animation_value_type="discrete"
|
||||||
spec="https://drafts.csswg.org/css-lists/#propdef-counter-increment">
|
spec="https://drafts.csswg.org/css-lists/#propdef-counter-increment">
|
||||||
use std::fmt;
|
use std::fmt;
|
||||||
use style_traits::ToCss;
|
use style_traits::ToCss;
|
||||||
|
@ -350,7 +350,7 @@
|
||||||
}
|
}
|
||||||
</%helpers:longhand>
|
</%helpers:longhand>
|
||||||
|
|
||||||
<%helpers:longhand name="counter-reset" animation_value_type="none"
|
<%helpers:longhand name="counter-reset" animation_value_type="discrete"
|
||||||
spec="https://drafts.csswg.org/css-lists-3/#propdef-counter-reset">
|
spec="https://drafts.csswg.org/css-lists-3/#propdef-counter-reset">
|
||||||
pub use super::counter_increment::{SpecifiedValue, computed_value, get_initial_value};
|
pub use super::counter_increment::{SpecifiedValue, computed_value, get_initial_value};
|
||||||
use super::counter_increment::parse_common;
|
use super::counter_increment::parse_common;
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue