diff options
author | Andreas Kling <kling@serenityos.org> | 2020-05-30 13:06:26 +0200 |
---|---|---|
committer | Andreas Kling <kling@serenityos.org> | 2020-05-30 13:06:26 +0200 |
commit | 7f22e2a3c47e53ffa31f864a99481865cfbd6867 (patch) | |
tree | 3fddee8126d663f72a2abed36650cdac512c9dc9 /Libraries/LibWeb/DOM/AttributeNames.cpp | |
parent | 770372ad029f211dbd0d7e9f3d4ffd59737b8660 (diff) | |
download | serenity-7f22e2a3c47e53ffa31f864a99481865cfbd6867.zip |
LibWeb: Use the globals from HTML::AttributeNames in style resolution
Using these avoids the FlyString lookups, so we should basically always
prefer them over string literal attribute names.
Diffstat (limited to 'Libraries/LibWeb/DOM/AttributeNames.cpp')
-rw-r--r-- | Libraries/LibWeb/DOM/AttributeNames.cpp | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/Libraries/LibWeb/DOM/AttributeNames.cpp b/Libraries/LibWeb/DOM/AttributeNames.cpp index c4c5b2b135..eda5c3f7e1 100644 --- a/Libraries/LibWeb/DOM/AttributeNames.cpp +++ b/Libraries/LibWeb/DOM/AttributeNames.cpp @@ -33,6 +33,8 @@ namespace AttributeNames { FlyString id; FlyString class_; FlyString type; +FlyString href; +FlyString style; void initialize() { @@ -42,6 +44,8 @@ void initialize() id = "id"; class_ = "class"; type = "type"; + href = "href"; + style = "style"; s_initialized = true; } |