Revert "Backport several style changes from Gecko (5) (#30099)" (#30104)

This reverts commit 8e15389cae.
This commit is contained in:
Oriol Brufau 2023-08-16 08:24:42 +02:00 committed by GitHub
parent 8e15389cae
commit d6ae8dc112
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
152 changed files with 4622 additions and 5862 deletions

View file

@ -19,7 +19,8 @@ use crate::selector_parser::Snapshot;
use crate::stylesheets::origin::OriginSet;
use crate::{Atom, WeakAtom};
use selectors::attr::CaseSensitivity;
use selectors::matching::{matches_selector, MatchingContext, MatchingMode, VisitedHandlingMode, NeedsSelectorFlags};
use selectors::matching::matches_selector;
use selectors::matching::{MatchingContext, MatchingMode, VisitedHandlingMode};
use selectors::NthIndexCache;
use smallvec::SmallVec;
@ -66,7 +67,6 @@ impl<'a, 'b: 'a, E: TElement + 'b> StateAndAttrInvalidationProcessor<'a, 'b, E>
Some(nth_index_cache),
VisitedHandlingMode::AllLinksVisitedAndUnvisited,
shared_context.quirks_mode(),
NeedsSelectorFlags::No,
);
Self {
@ -84,7 +84,7 @@ pub fn check_dependency<E, W>(
dependency: &Dependency,
element: &E,
wrapper: &W,
context: &mut MatchingContext<'_, E::Impl>,
mut context: &mut MatchingContext<'_, E::Impl>,
) -> bool
where
E: TElement,
@ -95,7 +95,8 @@ where
dependency.selector_offset,
None,
element,
context,
&mut context,
&mut |_, _| {},
);
let matched_then = matches_selector(
@ -103,7 +104,8 @@ where
dependency.selector_offset,
None,
wrapper,
context,
&mut context,
&mut |_, _| {},
);
matched_then != matches_now