auto merge of #4141 : SimonSapin/servo/style-cleanup, r=jdm

This commit is contained in:
bors-servo 2014-11-29 00:51:43 -07:00
commit e9aec8b9a7
3 changed files with 13 additions and 22 deletions

View file

@ -46,7 +46,7 @@ pub use properties::{cascade, cascade_anonymous, computed};
pub use properties::{PropertyDeclaration, ComputedValues, computed_values, style_structs};
pub use properties::{PropertyDeclarationBlock, parse_style_attribute}; // Style attributes
pub use properties::{CSSFloat, DeclaredValue, PropertyDeclarationParseResult};
pub use properties::{longhands, Angle, AngleOrCorner, AngleAoc, CornerAoc};
pub use properties::{Angle, AngleOrCorner, AngleAoc, CornerAoc};
pub use properties::{Left, Right, Bottom, Top};
pub use node::{TElement, TElementAttributes, TNode};
pub use selectors::{PseudoElement, Before, After, SelectorList, parse_selector_list_from_str};

View file

@ -10,8 +10,6 @@ pub use servo_util::geometry::Au;
pub type CSSFloat = f64;
pub static DEFAULT_LINE_HEIGHT: CSSFloat = 1.14;
pub mod specified {
use std::ascii::AsciiExt;
use std::f64::consts::PI;

View file

@ -1487,11 +1487,8 @@ mod property_bit_field {
fn set(&mut self, bit: uint) {
self.storage[bit / uint::BITS] |= 1 << (bit % uint::BITS)
}
#[inline]
fn clear(&mut self, bit: uint) {
self.storage[bit / uint::BITS] &= !(1 << (bit % uint::BITS))
}
% for i, property in enumerate(LONGHANDS):
% if property.derived_from is None:
#[allow(non_snake_case)]
#[inline]
pub fn get_${property.ident}(&self) -> bool {
@ -1502,11 +1499,7 @@ mod property_bit_field {
pub fn set_${property.ident}(&mut self) {
self.set(${i})
}
#[allow(non_snake_case)]
#[inline]
pub fn clear_${property.ident}(&mut self) {
self.clear(${i})
}
% endif
% endfor
}
}