mirror of
https://github.com/servo/servo.git
synced 2025-08-03 12:40:06 +01:00
Make PropertyDeclarationBlock::important_count private.
This commit is contained in:
parent
460fd6eba8
commit
da4e5146e9
10 changed files with 183 additions and 219 deletions
|
@ -62,10 +62,7 @@ impl CSSStyleOwner {
|
|||
let result = f(&mut pdb, &mut changed);
|
||||
result
|
||||
} else {
|
||||
let mut pdb = PropertyDeclarationBlock {
|
||||
important_count: 0,
|
||||
declarations: vec![],
|
||||
};
|
||||
let mut pdb = PropertyDeclarationBlock::new();
|
||||
let result = f(&mut pdb, &mut changed);
|
||||
|
||||
// Here `changed` is somewhat silly, because we know the
|
||||
|
@ -116,10 +113,7 @@ impl CSSStyleOwner {
|
|||
match *el.style_attribute().borrow() {
|
||||
Some(ref pdb) => f(&pdb.read()),
|
||||
None => {
|
||||
let pdb = PropertyDeclarationBlock {
|
||||
important_count: 0,
|
||||
declarations: vec![],
|
||||
};
|
||||
let pdb = PropertyDeclarationBlock::new();
|
||||
f(&pdb)
|
||||
}
|
||||
}
|
||||
|
|
|
@ -385,10 +385,9 @@ impl LayoutElementHelpers for LayoutJS<Element> {
|
|||
#[inline]
|
||||
fn from_declaration(declaration: PropertyDeclaration) -> ApplicableDeclarationBlock {
|
||||
ApplicableDeclarationBlock::from_declarations(
|
||||
Arc::new(RwLock::new(PropertyDeclarationBlock {
|
||||
declarations: vec![(declaration, Importance::Normal)],
|
||||
important_count: 0,
|
||||
})),
|
||||
Arc::new(RwLock::new(PropertyDeclarationBlock::with_one(
|
||||
declaration, Importance::Normal
|
||||
))),
|
||||
CascadeLevel::PresHints)
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue