mirror of
https://github.com/servo/servo.git
synced 2025-08-06 14:10:11 +01:00
Upgrade Stylo to 2024-04-16 (#32128)
* Upgrade Stylo to 2024-04-16 * Fixup for https://phabricator.services.mozilla.com/D205051 * Fixup for https://phabricator.services.mozilla.com/D203153 * Fixup for https://phabricator.services.mozilla.com/D202460 * Fixup for https://phabricator.services.mozilla.com/D205718 * Fixup for https://phabricator.services.mozilla.com/D206428 * Update test expectations
This commit is contained in:
parent
1440406e91
commit
401e49010f
13 changed files with 65 additions and 175 deletions
|
@ -414,15 +414,16 @@ impl<'dom> style::dom::TElement for ServoLayoutElement<'dom> {
|
|||
self.element.get_selector_flags().contains(flags)
|
||||
}
|
||||
|
||||
fn relative_selector_search_direction(&self) -> Option<ElementSelectorFlags> {
|
||||
let flags = self.element.get_selector_flags().intersection(
|
||||
ElementSelectorFlags::RELATIVE_SELECTOR_SEARCH_DIRECTION_ANCESTOR_SIBLING,
|
||||
);
|
||||
if flags.is_empty() {
|
||||
None
|
||||
} else {
|
||||
Some(flags)
|
||||
}
|
||||
fn relative_selector_search_direction(&self) -> ElementSelectorFlags {
|
||||
self.element
|
||||
.get_selector_flags()
|
||||
.intersection(ElementSelectorFlags::RELATIVE_SELECTOR_SEARCH_DIRECTION_ANCESTOR_SIBLING)
|
||||
}
|
||||
|
||||
fn each_custom_state<F>(&self, _callback: F)
|
||||
where
|
||||
F: FnMut(&AtomIdent),
|
||||
{
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -551,6 +552,7 @@ impl<'dom> ::selectors::Element for ServoLayoutElement<'dom> {
|
|||
NonTSPseudoClass::Link | NonTSPseudoClass::AnyLink => self.is_link(),
|
||||
NonTSPseudoClass::Visited => false,
|
||||
|
||||
NonTSPseudoClass::CustomState(ref state) => self.has_custom_state(&state.0),
|
||||
NonTSPseudoClass::Lang(ref lang) => self.match_element_lang(None, lang),
|
||||
|
||||
NonTSPseudoClass::ServoNonZeroBorder => !matches!(
|
||||
|
@ -651,6 +653,10 @@ impl<'dom> ::selectors::Element for ServoLayoutElement<'dom> {
|
|||
each_relevant_element_hash(*self, |hash| filter.insert_hash(hash & BLOOM_HASH_MASK));
|
||||
true
|
||||
}
|
||||
|
||||
fn has_custom_state(&self, _name: &AtomIdent) -> bool {
|
||||
false
|
||||
}
|
||||
}
|
||||
|
||||
/// A wrapper around elements that ensures layout can only
|
||||
|
@ -893,4 +899,8 @@ impl<'dom> ::selectors::Element for ServoThreadSafeLayoutElement<'dom> {
|
|||
});
|
||||
true
|
||||
}
|
||||
|
||||
fn has_custom_state(&self, _name: &AtomIdent) -> bool {
|
||||
false
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue