mirror of
https://github.com/servo/servo.git
synced 2025-08-11 00:15:32 +01:00
make list-style-type animatable
This commit is contained in:
parent
3e40d670dd
commit
73dfc28413
2 changed files with 18 additions and 2 deletions
|
@ -4142,6 +4142,23 @@ fn static_assert() {
|
|||
self.copy_list_style_type_from(other)
|
||||
}
|
||||
|
||||
pub fn clone_list_style_type(&self) -> longhands::list_style_type::computed_value::T {
|
||||
use gecko_bindings::bindings::Gecko_CounterStyle_IsSingleString;
|
||||
use gecko_bindings::bindings::Gecko_CounterStyle_GetSingleString;
|
||||
use self::longhands::list_style_type::computed_value::T;
|
||||
use values::generics::CounterStyleOrNone;
|
||||
|
||||
if unsafe { Gecko_CounterStyle_IsSingleString(&self.gecko.mCounterStyle) } {
|
||||
ns_auto_string!(single_string);
|
||||
unsafe {
|
||||
Gecko_CounterStyle_GetSingleString(&self.gecko.mCounterStyle, &mut *single_string)
|
||||
};
|
||||
T::String(single_string.to_string())
|
||||
} else {
|
||||
T::CounterStyle(CounterStyleOrNone::from_gecko_value(&self.gecko.mCounterStyle))
|
||||
}
|
||||
}
|
||||
|
||||
pub fn set_quotes(&mut self, other: longhands::quotes::computed_value::T) {
|
||||
use gecko_bindings::bindings::Gecko_NewStyleQuoteValues;
|
||||
use gecko_bindings::sugar::refptr::UniqueRefPtr;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue