mirror of
https://github.com/RGBCube/serenity
synced 2025-07-27 13:07:46 +00:00
LibWeb: Initialize PseudoClass/PseudoElement selectors in one go
There was no real benefit to creating the SimpleSelector early and then modifying it, and doing so made this code harder to follow than it needs to be.
This commit is contained in:
parent
c0db19f63c
commit
75ec960495
2 changed files with 120 additions and 111 deletions
|
@ -85,12 +85,12 @@ public:
|
|||
|
||||
// FIXME: We don't need this field on every single SimpleSelector, but it's also annoying to malloc it somewhere.
|
||||
// Only used when "pseudo_class" is "NthChild" or "NthLastChild".
|
||||
ANPlusBPattern nth_child_pattern;
|
||||
ANPlusBPattern nth_child_pattern {};
|
||||
|
||||
SelectorList argument_selector_list {};
|
||||
|
||||
// Used for :lang(en-gb,dk)
|
||||
Vector<FlyString> languages;
|
||||
Vector<FlyString> languages {};
|
||||
};
|
||||
|
||||
struct Attribute {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue