mirror of
https://github.com/servo/servo.git
synced 2025-08-03 04:30:10 +01:00
Limit visited cascade for reparenting
The specialized cascade flow in `stylist::compute_style_with_inputs` (used with reparenting) currently computes all properties for visited styles, but we only need visited-dependent properties. This adds the cascade flag to reduce the work to visited-dependent properties only, like we do for the regular cascade flow. MozReview-Commit-ID: FGCj6GPnQOB
This commit is contained in:
parent
9f8514d2b9
commit
0eb7d65e73
1 changed files with 2 additions and 1 deletions
|
@ -25,6 +25,7 @@ use properties::{AnimationRules, PropertyDeclarationBlock};
|
|||
#[cfg(feature = "servo")]
|
||||
use properties::INHERIT_ALL;
|
||||
use properties::IS_LINK;
|
||||
use properties::VISITED_DEPENDENT_ONLY;
|
||||
use rule_tree::{CascadeLevel, RuleTree, StrongRuleNode, StyleSource};
|
||||
use selector_map::{PrecomputedHashMap, SelectorMap, SelectorMapEntry};
|
||||
use selector_parser::{SelectorImpl, PerPseudoElementMap, PseudoElement};
|
||||
|
@ -924,7 +925,7 @@ impl Stylist {
|
|||
Some(layout_parent_style_for_visited),
|
||||
None,
|
||||
font_metrics,
|
||||
cascade_flags,
|
||||
cascade_flags | VISITED_DEPENDENT_ONLY,
|
||||
self.quirks_mode,
|
||||
/* rule_cache = */ None,
|
||||
&mut Default::default(),
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue