auto merge of #4342 : jdm/servo/cssom, r=jdm,metajack

This does not implement any notion of CSSStyleDeclaration objects that do not have an owning element; there's no actual CSS object model in play here. This does support setting and getting properties of the style attribute for HTMLElement, and tries to implement the ambiguous CSS value serialization spec.
This commit is contained in:
bors-servo 2014-12-18 11:54:52 -07:00
commit 824788649c
16 changed files with 1705 additions and 47 deletions

View file

@ -6,6 +6,7 @@
//! `<input size>`, and so forth.
use node::{TElement, TElementAttributes, TNode};
use properties::common_types::specified::CSSColor;
use properties::DeclaredValue::SpecifiedValue;
use properties::PropertyDeclaration::*;
use properties::{CSSFloat, specified};
@ -211,7 +212,7 @@ impl PresentationalHintSynthesis for Stylist {
None => {}
Some(color) => {
matching_rules_list.vec_push(DeclarationBlock::from_declaration(
BackgroundColorDeclaration(SpecifiedValue(Color::RGBA(color)))));
BackgroundColorDeclaration(SpecifiedValue(CSSColor { parsed: Color::RGBA(color), authored: None }))));
*shareable = false
}
}