mirror of
https://github.com/servo/servo.git
synced 2025-08-06 14:10:11 +01:00
style: Use precomputation for the -servo-details-content pseudo-element
This commit is contained in:
parent
b6402a81d0
commit
3563ecb770
4 changed files with 42 additions and 32 deletions
|
@ -159,15 +159,14 @@ impl SelectorImpl for ServoSelectorImpl {
|
|||
impl SelectorImplExt for ServoSelectorImpl {
|
||||
type ComputedValues = ServoComputedValues;
|
||||
|
||||
// TODO: Making details-summary not eagerly cascaded shouldn't be difficult
|
||||
#[inline]
|
||||
fn is_eagerly_cascaded_pseudo_element(pseudo: &PseudoElement) -> bool {
|
||||
match *pseudo {
|
||||
PseudoElement::Before |
|
||||
PseudoElement::After |
|
||||
PseudoElement::Selection |
|
||||
PseudoElement::DetailsContent |
|
||||
PseudoElement::DetailsSummary => true,
|
||||
PseudoElement::DetailsContent => false,
|
||||
}
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue