Bug 130091 - Don't use NodeRenderingTraversal for pseudo elements
Summary: Don't use NodeRenderingTraversal for pseudo elements
Status: RESOLVED FIXED
Alias: None
Product: WebKit
Classification: Unclassified
Component: DOM (show other bugs)
Version: 528+ (Nightly build)
Hardware: Unspecified Unspecified
: P2 Normal
Assignee: Nobody
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2014-03-11 08:52 PDT by Antti Koivisto
Modified: 2022-08-11 13:24 PDT (History)
1 user (show)

See Also:


Attachments
patch (30.96 KB, patch)
2014-03-11 15:36 PDT, Antti Koivisto
kling: review+
Details | Formatted Diff | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Antti Koivisto 2014-03-11 08:52:25 PDT
Make traversing during style resolve more comprehensible by handling before/after pseudo elements explicitly.
Comment 1 Antti Koivisto 2014-03-11 15:36:54 PDT
Created attachment 226437 [details]
patch
Comment 2 Andreas Kling 2014-03-11 15:52:35 PDT
Comment on attachment 226437 [details]
patch

View in context: https://bugs.webkit.org/attachment.cgi?id=226437&action=review

r=me

> Source/WebCore/dom/NodeRenderingTraversal.cpp:221
> +Node* firstChildSlow(const Node* node)

This code could be made more efficient by exploiting the knowledge that only Elements will have the shouldUseNodeRenderingTraversalSlowPath bit set.

> Source/WebCore/dom/NodeRenderingTraversal.h:39
> +Node* lastChild(const Node*);

Where is this?

> Source/WebCore/dom/NodeRenderingTraversal.h:63
> +inline Node* firstChild(const Node* node)

Again, could be better with Element*.
Comment 3 Ahmad Saleem 2022-08-11 13:24:28 PDT
It seems that it was landed but not marked as "RESOLVED FIXED".

https://github.com/WebKit/WebKit/commit/d31ae33de07e70eca6498f4f103f7581ba6b9276

and it didn't backed out. I am going to mark this as "RESOLVED FIXED". Thanks!