Move bgcolor over to the new infrastructure.

Note that I call is_htmltabledatacellelement in
synthesize_presentational_hints_for_legacy_attributes, rather than
is_htmltablecellelement (which was used in
get_simple_color_attribute_for_layout), because that function was never called
for th elements.
This commit is contained in:
Ms2ger 2015-04-26 22:22:12 +02:00
parent 582ee1c2b3
commit e3440c8a59
4 changed files with 33 additions and 102 deletions

View file

@ -5,8 +5,7 @@
//! Traits that nodes must implement. Breaks the otherwise-cyclic dependency between layout and
//! style.
use cssparser::RGBA;
use legacy::{IntegerAttribute, LengthAttribute, SimpleColorAttribute, UnsignedIntegerAttribute};
use legacy::{IntegerAttribute, LengthAttribute, UnsignedIntegerAttribute};
use properties::PropertyDeclaration;
use util::str::LengthOrPercentageOrAuto;
@ -20,5 +19,4 @@ pub trait TElementAttributes : Copy {
fn get_length_attribute(self, attribute: LengthAttribute) -> LengthOrPercentageOrAuto;
fn get_integer_attribute(self, attribute: IntegerAttribute) -> Option<i32>;
fn get_unsigned_integer_attribute(self, attribute: UnsignedIntegerAttribute) -> Option<u32>;
fn get_simple_color_attribute(self, attribute: SimpleColorAttribute) -> Option<RGBA>;
}