mirror of
https://github.com/servo/servo.git
synced 2025-07-23 07:13:52 +01:00
Bug 1345950: stylo: Fix slow selector flags. r=bholley
MozReview-Commit-ID: QwuSxulNG0 Signed-off-by: Emilio Cobos Álvarez <emilio@crisal.io>
This commit is contained in:
parent
f90f7d6824
commit
a9b133bcbb
9 changed files with 288 additions and 189 deletions
|
@ -615,10 +615,13 @@ impl<'le> ::selectors::Element for ServoLayoutElement<'le> {
|
|||
self.element.namespace()
|
||||
}
|
||||
|
||||
fn match_non_ts_pseudo_class(&self,
|
||||
pseudo_class: &NonTSPseudoClass,
|
||||
_: &mut StyleRelations,
|
||||
_: &mut ElementSelectorFlags) -> bool {
|
||||
fn match_non_ts_pseudo_class<F>(&self,
|
||||
pseudo_class: &NonTSPseudoClass,
|
||||
_: &mut StyleRelations,
|
||||
_: &mut F)
|
||||
-> bool
|
||||
where F: FnMut(&Self, ElementSelectorFlags),
|
||||
{
|
||||
match *pseudo_class {
|
||||
// https://github.com/servo/servo/issues/8718
|
||||
NonTSPseudoClass::Link |
|
||||
|
@ -1114,10 +1117,13 @@ impl<'le> ::selectors::Element for ServoThreadSafeLayoutElement<'le> {
|
|||
self.element.get_namespace()
|
||||
}
|
||||
|
||||
fn match_non_ts_pseudo_class(&self,
|
||||
_: &NonTSPseudoClass,
|
||||
_: &mut StyleRelations,
|
||||
_: &mut ElementSelectorFlags) -> bool {
|
||||
fn match_non_ts_pseudo_class<F>(&self,
|
||||
_: &NonTSPseudoClass,
|
||||
_: &mut StyleRelations,
|
||||
_: &mut F)
|
||||
-> bool
|
||||
where F: FnMut(&Self, ElementSelectorFlags),
|
||||
{
|
||||
// NB: This could maybe be implemented
|
||||
warn!("ServoThreadSafeLayoutElement::match_non_ts_pseudo_class called");
|
||||
false
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue