mirror of
https://github.com/servo/servo.git
synced 2025-08-06 06:00:15 +01:00
style: Unbox a bunch of color properties.
This builds on https://github.com/servo/rust-cssparser/pull/118.
This commit is contained in:
parent
e394334739
commit
0c102e2350
37 changed files with 185 additions and 195 deletions
|
@ -407,7 +407,7 @@ impl LayoutElementHelpers for LayoutJS<Element> {
|
|||
if let Some(color) = bgcolor {
|
||||
hints.push(from_declaration(
|
||||
PropertyDeclaration::BackgroundColor(DeclaredValue::Value(
|
||||
Box::new(CSSColor { parsed: Color::RGBA(color), authored: None })))));
|
||||
CSSColor { parsed: Color::RGBA(color), authored: None }))));
|
||||
}
|
||||
|
||||
let background = if let Some(this) = self.downcast::<HTMLBodyElement>() {
|
||||
|
@ -440,10 +440,10 @@ impl LayoutElementHelpers for LayoutJS<Element> {
|
|||
|
||||
if let Some(color) = color {
|
||||
hints.push(from_declaration(
|
||||
PropertyDeclaration::Color(DeclaredValue::Value(Box::new(CSSRGBA {
|
||||
PropertyDeclaration::Color(DeclaredValue::Value(CSSRGBA {
|
||||
parsed: color,
|
||||
authored: None,
|
||||
})))));
|
||||
}))));
|
||||
}
|
||||
|
||||
let font_family = if let Some(this) = self.downcast::<HTMLFontElement>() {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue