mirror of
https://github.com/servo/servo.git
synced 2025-08-07 14:35:33 +01:00
Auto merge of #17658 - emilio:nesting-level, r=bholley
selectors: Avoid looking at MatchingMode if the selector isn't the topmost. Also, switch the hover quirk to the same mechanism. Bug: 1379696 Reviewed-By: bholley MozReview-Commit-ID: KrmNqNyASf6 <!-- Reviewable:start --> --- This change is [<img src="https://reviewable.io/review_button.svg" height="34" align="absmiddle" alt="Reviewable"/>](https://reviewable.io/reviews/servo/servo/17658) <!-- Reviewable:end -->
This commit is contained in:
commit
8fa2a262dc
2 changed files with 31 additions and 21 deletions
|
@ -1778,12 +1778,11 @@ impl<'le> ::selectors::Element for GeckoElement<'le> {
|
|||
}
|
||||
NonTSPseudoClass::MozPlaceholder => false,
|
||||
NonTSPseudoClass::MozAny(ref sels) => {
|
||||
let old_value = context.hover_active_quirk_disabled;
|
||||
context.hover_active_quirk_disabled = true;
|
||||
context.nesting_level += 1;
|
||||
let result = sels.iter().any(|s| {
|
||||
matches_complex_selector(s.iter(), self, context, flags_setter)
|
||||
});
|
||||
context.hover_active_quirk_disabled = old_value;
|
||||
context.nesting_level -= 1;
|
||||
result
|
||||
}
|
||||
NonTSPseudoClass::Lang(ref lang_arg) => {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue