mirror of
https://github.com/servo/servo.git
synced 2025-08-03 12:40:06 +01:00
style: Simplify PropertyDeclarationBlock::get a little.
Depends On D3747 Differential Revision: https://phabricator.services.mozilla.com/D3748
This commit is contained in:
parent
b20bbea033
commit
249b865eb8
1 changed files with 2 additions and 8 deletions
|
@ -305,14 +305,8 @@ impl PropertyDeclarationBlock {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
self.declarations.iter().enumerate().find(|&(_, decl)| decl.id() == property).map(|(i, decl)| {
|
self.declaration_importance_iter()
|
||||||
let importance = if self.declarations_importance[i] {
|
.find(|(declaration, _)| declaration.id() == property)
|
||||||
Importance::Important
|
|
||||||
} else {
|
|
||||||
Importance::Normal
|
|
||||||
};
|
|
||||||
(decl, importance)
|
|
||||||
})
|
|
||||||
}
|
}
|
||||||
|
|
||||||
fn shorthand_to_css(
|
fn shorthand_to_css(
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue