implements nsStyleQuoteValues type properties animatable

This commit is contained in:
Daisuke Akatsuka 2017-07-05 13:00:02 +09:00
parent 7d1374e019
commit 0555977c66
2 changed files with 12 additions and 1 deletions

View file

@ -3303,6 +3303,17 @@ fn static_assert() {
unsafe { self.gecko.mQuotes.set(&other.gecko.mQuotes); } unsafe { self.gecko.mQuotes.set(&other.gecko.mQuotes); }
} }
pub fn clone_quotes(&self) -> longhands::quotes::computed_value::T {
unsafe {
let ref gecko_quote_values = *self.gecko.mQuotes.mRawPtr;
longhands::quotes::computed_value::T(
gecko_quote_values.mQuotePairs.iter().map(|gecko_pair| {
(gecko_pair.first.to_string(), gecko_pair.second.to_string())
}).collect()
)
}
}
#[allow(non_snake_case)] #[allow(non_snake_case)]
pub fn set__moz_image_region(&mut self, v: longhands::_moz_image_region::computed_value::T) { pub fn set__moz_image_region(&mut self, v: longhands::_moz_image_region::computed_value::T) {
use values::Either; use values::Either;

View file

@ -142,7 +142,7 @@ ${helpers.single_keyword("list-style-position", "outside inside", animation_valu
} }
</%helpers:longhand> </%helpers:longhand>
<%helpers:longhand name="quotes" animation_value_type="none" <%helpers:longhand name="quotes" animation_value_type="discrete"
spec="https://drafts.csswg.org/css-content/#propdef-quotes"> spec="https://drafts.csswg.org/css-content/#propdef-quotes">
use cssparser::serialize_string; use cssparser::serialize_string;
use std::fmt; use std::fmt;