style: Introduce a generic way of gathering information from the cascade, and use it for viewport units.

This commit is contained in:
Emilio Cobos Álvarez 2016-08-12 16:30:35 -07:00
parent 40c04b4c6b
commit 9e88a495c8
No known key found for this signature in database
GPG key ID: 056B727BB9C1027C
12 changed files with 205 additions and 23 deletions

View file

@ -39,6 +39,12 @@ pub struct SpecifiedValue {
references: HashSet<Name>,
}
impl ::values::HasViewportPercentage for SpecifiedValue {
fn has_viewport_percentage(&self) -> bool {
panic!("has_viewport_percentage called before resolving!");
}
}
pub struct BorrowedSpecifiedValue<'a> {
css: &'a str,
first_token_type: TokenSerializationType,